summaryrefslogtreecommitdiff
path: root/wk4
diff options
context:
space:
mode:
Diffstat (limited to 'wk4')
-rw-r--r--wk4/lect/memory.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/wk4/lect/memory.c b/wk4/lect/memory.c
index c4e6de0..26cff19 100644
--- a/wk4/lect/memory.c
+++ b/wk4/lect/memory.c
@@ -7,7 +7,7 @@
int main(void)
{
int *x = malloc(3 *sizeof(int));
- x[1] = 72;
- x[2] = 73;
- x[3] = 33;
+ x[0] = 72;
+ x[1] = 73;
+ x[2] = 33;
}