Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions add
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
#include <stdio.h>
#include <lib.h>
int main() {

int num1, num2, num3,num4, sum;

printf("Enter the first number: ");
scanf("%d", &num1);

printf("Enter the second number: ");
scanf("%d", &num2);

printf("Enter the third number: ");
scanf("%d", &num3);

printf("Enter the fourth number: ");
scanf("%d", &num4);


sum = num1 + num2 + num3 + num4 + sum ;

printf("The sum of %d and %d is %d.", num1, num2, sum);

return 0;
}
8 changes: 6 additions & 2 deletions add.c
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

int main() {

int num1, num2, num3, sum;
int num1, num2, num3,num4, sum;

printf("Enter the first number: ");
scanf("%d", &num1);
Expand All @@ -12,8 +12,12 @@ int main() {

printf("Enter the third number: ");
scanf("%d", &num3);

printf("Enter the fourth number: ");
scanf("%d", &num4);

sum = num1 + num2 + num3;

sum = num1 + num2 + num3 + num4;

printf("The sum of %d and %d is %d.", num1, num2, sum);

Expand Down
2 changes: 2 additions & 0 deletions name
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
name = "natasha"
print("My name is", natasha)
2 changes: 0 additions & 2 deletions name.py

This file was deleted.

Binary file added ~$add.c
Binary file not shown.