mirror of
https://github.com/janishutz/eth-summaries.git
synced 2026-01-12 01:58:24 +00:00
[SPCA] Restructre, some notes
This commit is contained in:
@@ -12,5 +12,5 @@ int main( int argc, char *argv[] ) {
|
||||
for ( int i = 0; i < argc; i++ ) // For loop just like any other sane programming language
|
||||
printf( "Arg %d: %s\n", i, argv[ i ] ); // Outputs the i-th argument from CLI
|
||||
|
||||
get_user_input_int( "Select a number" );
|
||||
get_user_input_int( "Select a number" ); // Function calls as in any other language
|
||||
}
|
||||
@@ -25,12 +25,12 @@ int get_user_input_int( char prompt[] ) {
|
||||
|
||||
while ( input_data > 1 ) {
|
||||
input_data -= 1;
|
||||
printf( "Hello World" );
|
||||
printf( "Hello World\n" );
|
||||
}
|
||||
|
||||
do {
|
||||
input_data -= 1;
|
||||
printf( "Bye World" );
|
||||
printf( "Bye World\n" );
|
||||
} while ( input_data_copy > 1 );
|
||||
|
||||
return 0;
|
||||
0
semester3/spca/code-examples/00_c/02_pointers.c
Normal file
0
semester3/spca/code-examples/00_c/02_pointers.c
Normal file
0
semester3/spca/code-examples/00_c/02_pointers.h
Normal file
0
semester3/spca/code-examples/00_c/02_pointers.h
Normal file
Reference in New Issue
Block a user