Commit 2f54c510 by emonyi

Upload New File

parent 29bbb025
Showing with 28 additions and 0 deletions
/*
* Bonus Task 2
* */
#include <stdio.h>
#include <stdlib.h>
int main(){
int i;
int array[6], sum=0;
for(i=0; i < 6; i++){
array[i]= i + 1;
printf("%d\n", array[i]);
}
for(i=0; i < 6; i++){
sum=sum + array[i];
printf("%d ", sum);
}
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment