annotate test01.c @ 0:bacef8675607

init repository
author Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
date Tue, 14 Oct 2014 17:34:59 +0900
parents
children 35d6eabeadb0
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
1 #include<stdio.h>
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
2
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
3 int test_code(void){
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
4 printf("\t\ttest_code: return 10\n");
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
5 return 10;
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
6 }
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
7
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
8 int test_goto(int a){
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
9 printf("\ttest_goto: a = %d\n", a);
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
10 //return test_code();
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
11 return test_code();
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
12 }
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
13
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
14 int main(int argc, char **argv){
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
15 int ret;
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
16 printf("test code\n");
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
17 ret = test_goto(20);
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
18 printf("main: ret = %d\n", ret);
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
19
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
20 return test_goto2(10,20,30,40,50,60,70,80,90,100);
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
21 return 0;
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
22 }
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
23
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
24 int test_code2(int a,int b,int c,int d,int e,int f,int g,int h,int i,int j,int k){
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
25 printf("\t\ttest_code: return 10\n");
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
26 printf("a=%d,b=%d,c=%d,d=%d,e=%d,f=%d,g=%d,h=%d,i=%d,j=%d,k=%d\n",a,b,c,d,e,f,g,h,i,j,k );
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
27 return a+b+c+d+e+f+g+h+i+j+k;
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
28 }
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
29
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
30 int test_goto2(int a,int b,int c,int d,int e,int f,int g,int h,int i,int j,int k){
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
31 printf("\ttest_goto: a = %d\n", a);
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
32 //return test_code();
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
33 return test_code2(a,b,c,d,e,f,g,h,i,j,k);
bacef8675607 init repository
Kaito Tokumori <e105711@ie.u-ryukyu.ac.jp>
parents:
diff changeset
34 }