From 4b38fc2aef963ee0b7c360d6dfa022e76f9886cb Mon Sep 17 00:00:00 2001 From: Sampul-CodeMine Date: Sat, 21 Jan 2023 13:09:24 +0100 Subject: [PATCH 01/19] Solution to all tasks 1 - 15 - Dukeson --- TASKS/README.md | 1 + TASKS/Task 001.c | 25 ++++++++++++++++++++----- TASKS/Task 002.c | 32 ++++++++++++++++++++++++++------ TASKS/Task 003.c | 28 +++++++++++++++++++++------- TASKS/Task 004.c | 42 +++++++++++++++++++++++++++++++----------- TASKS/Task 005.c | 31 +++++++++++++++++++++++++++---- TASKS/Task 006.c | 24 +++++++++++++++++++++++- TASKS/Task 007.c | 35 ++++++++++++++++++++++++++++++++++- TASKS/Task 008.c | 35 ++++++++++++++++++++++++++++++++++- TASKS/Task 009.c | 25 ++++++++++++++++++++++++- TASKS/Task 010.c | 27 ++++++++++++++++++++++++++- TASKS/Task 011.c | 18 +++++++++++++++++- TASKS/Task 012.c | 34 +++++++++++++++++++++++++++++++++- TASKS/Task 013.c | 28 +++++++++++++++++++++++++++- TASKS/Task 014.c | 27 ++++++++++++++++++++++++++- TASKS/Task 015.c | 24 +++++++++++++++++++++++- 16 files changed, 393 insertions(+), 43 deletions(-) diff --git a/TASKS/README.md b/TASKS/README.md index d541f8d..4b765fe 100644 --- a/TASKS/README.md +++ b/TASKS/README.md @@ -1 +1,2 @@ this directory contains tasks on each of the lessons of c programming, attempt each of them before asking or checking the solutions. + diff --git a/TASKS/Task 001.c b/TASKS/Task 001.c index 24be041..43c737f 100644 --- a/TASKS/Task 001.c +++ b/TASKS/Task 001.c @@ -1,7 +1,22 @@ -/* Write your program after the comment -Write a program that prints the alphabet in lowercase, followed by a new line. +#include +#include -Print all the letters except q and e +/** + * Write your program after the comment + * Write a program that prints the alphabet in lowercase, followed by a new line. + * Print all the letters except q and e + * use printf + */ -use printf -*/ \ No newline at end of file +int main(void) +{ + char alpha; + + for (alpha = 'a'; alpha <= 'z'; alpha++) + { + if (alpha == 'e' || alpha == 'q') + continue; + printf("%c", alpha); + } + printf("\n"); +} diff --git a/TASKS/Task 002.c b/TASKS/Task 002.c index 5cdd390..c13f0b3 100644 --- a/TASKS/Task 002.c +++ b/TASKS/Task 002.c @@ -1,6 +1,26 @@ -/* Write your program after the comment -Write a program that asks and reads the score of a user -If the score is less than 80, display to the user that they -are not elgible to be enrolled. -If the score is greater than or equal 80, they can be enrolled. -*/ \ No newline at end of file +#include +#include +#include + +/** + * Write your program after the comment + * Write a program that asks and reads the score of a user + * If the score is less than 80, display to the user that they are not eligible to be enrolled. + * If the score is greater than or equal 80, they can be enrolled. + */ + +int main(void) +{ + int score = 0; + printf("Enter a Score:\t"); + if (scanf("%d", &score) == 1) + { + if (score < 80) + printf("You are not eligible to be enrolled."); + else if (score >= 80) + printf("You can be enrolled."); + } + else + printf("Your input is not a numeric data."); + return 0; +} diff --git a/TASKS/Task 003.c b/TASKS/Task 003.c index 7fca79c..0a88856 100644 --- a/TASKS/Task 003.c +++ b/TASKS/Task 003.c @@ -1,9 +1,23 @@ -/* Write your program after the comment -Write a program that reads input from user (Number) -If the number is Odd, display 'userInput is Odd' -If the number is even, display 'userInput is even' -If the number is zero, display 'This is zero' +#include +#include -NOTE: 'userInput' should be the number entered by the user. +/** + * Write your program after the comment + * Write a program that reads input from user (Number) + * If the number is Odd, display 'userInput is Odd' + * If the number is even, display 'userInput is even' + * If the number is zero, display 'This is zero' + * + * NOTE: 'userInput' should be the number entered by the user. + */ -*/ \ No newline at end of file +int main(void) +{ + int num = 0; + + printf("Enter Number:\t"); + scanf("%d", &num); + + (num == 0) ? printf("Input is Zero") : ((num % 2 == 0) ? printf("Input is even") : printf("input is odd")); + return (0); +} diff --git a/TASKS/Task 004.c b/TASKS/Task 004.c index 17ee38c..3479781 100644 --- a/TASKS/Task 004.c +++ b/TASKS/Task 004.c @@ -1,14 +1,34 @@ -/* Write your program after the comment -Write a program that asks and reads the following input from a use; -Your name -Your age -and then displays; Your name is 'name' and you are 'age' years old. +#include +#include -Example; -what is your name: David -How old are you?: 65 +/** + * Write your program after the comment + * Write a program that asks and reads the following input from a use; + * Your name + * Your age + * and then displays; Your name is 'name' and you are 'age' years old. + * + * Example; + * + * what is your name: David + * How old are you?: 65 + * + * Output: + * Your name is David and you are 65 years old. + */ -Output: -Your name is David and you are 65 years old. +int main(void) +{ + int age = 0; + char name[100]; -*/ \ No newline at end of file + printf("Enter Name:\t"); + scanf("%s", name); + + printf("Enter Age:\t"); + scanf("%d", &age); + + printf("Your name is %s and you are %d years old.", name, age); + + return (0); +} diff --git a/TASKS/Task 005.c b/TASKS/Task 005.c index db32ab3..08d6b8a 100644 --- a/TASKS/Task 005.c +++ b/TASKS/Task 005.c @@ -1,4 +1,27 @@ -/* - Write a program in C to find the square of any number -using the function. -*/ \ No newline at end of file +#include + +/** + * Write a program in C to find the square of any number + * using the function. + */ + + void return_square() + { + int num = 0, result; + + printf("Enter a Number:\t"); + if (scanf("%d", &num) == 1) + result = (num * num); + else + result = 0; + if (result == 0) + printf("\nThe data entered is not a number. The result is %d", result); + else + printf("\nThe square of %d = %d", num, result); + } + + int main(void) + { + return_square(); + return (0); + } \ No newline at end of file diff --git a/TASKS/Task 006.c b/TASKS/Task 006.c index dc0b9af..af09de4 100644 --- a/TASKS/Task 006.c +++ b/TASKS/Task 006.c @@ -1,4 +1,26 @@ +#include /* Write a program in C to check a given number is even or odd using the function. -*/ \ No newline at end of file +*/ +void type_checker() +{ + int num = 0; + + printf("Enter a Number:\t"); + if (scanf("%d", &num) == 1) + { + if ((num % 2) == 0) + printf("\nThe number %d is an even number.", num); + else + printf("\nThe number %d is an odd number.", num); + } + else + printf("\nThe data entered is not a number."); + +} +int main(void) +{ + type_checker(); + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 007.c b/TASKS/Task 007.c index 07ea0fb..2f09563 100644 --- a/TASKS/Task 007.c +++ b/TASKS/Task 007.c @@ -1,5 +1,38 @@ +#include +#include + /* write your solution after the comment Write a function that prints the alphabet, in uppercase, followed by a new line. -*/ \ No newline at end of file +*/ + +void to_upper_case_one() +{ + char n; + + for (n = 'A'; n <= 'Z'; n++) + { + printf("%c", n); + } + printf("\n"); +} + +void to_upper_case_two() +{ + char n; + + for (n = 'a'; n <= 'z'; n++) + { + printf("%c", toupper(n)); + } + printf("\n"); +} + +int main(void) +{ + to_upper_case_one(); + to_upper_case_two(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 008.c b/TASKS/Task 008.c index 0a815b2..2a4aed2 100644 --- a/TASKS/Task 008.c +++ b/TASKS/Task 008.c @@ -1,4 +1,37 @@ +#include +#include + /*write your solution after the comment Write a function that prints the alphabet, in lowercase followed by a new line. -*/ \ No newline at end of file +*/ + +void to_lower_case_one() +{ + char n; + + for (n = 'a'; n <= 'z'; n++) + { + printf("%c", n); + } + printf("\n"); +} + +void to_lower_case_two() +{ + char n; + + for (n = 'A'; n <= 'Z'; n++) + { + printf("%c", tolower(n)); + } + printf("\n"); +} + +int main(void) +{ + to_lower_case_one(); + to_lower_case_two(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 009.c b/TASKS/Task 009.c index d481f90..ca7b43c 100644 --- a/TASKS/Task 009.c +++ b/TASKS/Task 009.c @@ -1,5 +1,28 @@ +#include +#include +#include + /*write your solution after the comment Write a function that checks for lowercase character. That is, when passed in an arguments, it checks if the argument is lowercase or uppercase. -*/ \ No newline at end of file +*/ +void check_case(char chr) +{ + if ( chr >= 'a' && chr <= 'z') + printf("\n%c is a lower cased character.", chr); + else if (chr >= 'A' && chr <= 'Z') + printf("\n%c is an upper cased character.", chr); + else + printf("\nKindly provide a character."); +} +int main(void) +{ + char str; + + printf("Enter a character:\t"); + scanf("%c", &str); + check_case(str); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 010.c b/TASKS/Task 010.c index 62c07e9..1243610 100644 --- a/TASKS/Task 010.c +++ b/TASKS/Task 010.c @@ -1,5 +1,30 @@ +#include + /*write your solution after the comment Write a function that computes the absolute value of an integer. Understand what an absolute value is, before attempting it. -*/ \ No newline at end of file +*/ +int get_absolute(int num) +{ + if (num < 0) + num *= -1; + return (num); +} + +int main(void) +{ + int num = 0; + int result = 0; + + printf("Enter a Number:\t"); + if (scanf("%d", &num) == 1) + { + result = get_absolute(num); + printf("The absolute value of %d = %d", num, result); + } + else + printf("\nThe data entered is not a number."); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 011.c b/TASKS/Task 011.c index 96c4add..f8698ad 100644 --- a/TASKS/Task 011.c +++ b/TASKS/Task 011.c @@ -1,3 +1,5 @@ +#include + /*write your solution after the comment Write a function that prints the 9 times table, starting with 0. @@ -6,4 +8,18 @@ Output should look like this; 9 x 1 = 9 9 x 2 = 18 ... and so on till 12 -*/ \ No newline at end of file +*/ + +void times_table() +{ + int i = 9, j; + + for (j = 0; j <= 12; j++) + printf("%d * %d = %d\n", i, j, (i * j)); + printf("\n"); +} +int main(void) +{ + times_table(); + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 012.c b/TASKS/Task 012.c index 735a015..a99e386 100644 --- a/TASKS/Task 012.c +++ b/TASKS/Task 012.c @@ -1,4 +1,36 @@ +#include +#include /*Write your solution after the comment Write a function that adds two integers and prints the result. -*/ \ No newline at end of file +*/ + +int accept_value(char *chr) +{ + int var = 0; + + printf("Enter %s Value:\t", chr); + if( scanf("%d", &var) == 1) + return (var); + else + return (0); +} + +void add_up() +{ + int sum = 0; + int first; + int second; + + first = accept_value("First"); + second = accept_value("Second"); + sum = (first + second); + printf("\nThe sum of %d + %d = %d.\n", first, second, sum); +} + +int main(void) +{ + add_up(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 013.c b/TASKS/Task 013.c index 068a6cc..4316cc4 100644 --- a/TASKS/Task 013.c +++ b/TASKS/Task 013.c @@ -1,6 +1,32 @@ +#include + /*Write your solution after the comment Write a function that prints all natural numbers from n to 100, followed by a new line. That is n is your argument, it should print from any number passed as argument till 100. -*/ \ No newline at end of file +*/ + +void natural_num_print(int arg) +{ + int count = 100; + + while (arg <= count) + { + printf("%d ", arg); + arg++; + } + printf("\n"); +} +int main(void) +{ + int num = 0; + + printf("Enter A Value:\t"); + if (scanf("%d", &num) == 1) + natural_num_print(num); + else + printf("\nPlease enter a number."); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 014.c b/TASKS/Task 014.c index d139cd2..64ac4ed 100644 --- a/TASKS/Task 014.c +++ b/TASKS/Task 014.c @@ -1,3 +1,5 @@ +#include + /*Write your solution after the comment Write a function that prints 10 times the numbers, from 0 to 14, followed by a new line. @@ -6,4 +8,27 @@ Your output should look like this; 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 0 1 2 3 4 5 6 7 8 9 10 11 12 13 14 ...up to 10 times -*/ \ No newline at end of file +*/ + +void print_14() +{ + int i; + + for (i = 0; i <= 14; i++) + printf("%d ", i); + printf("\n"); +} +void print_10() +{ + int i; + + for (i = 0; i < 10; i++) + print_14(); + printf("\n"); +} + +int main(void) +{ + print_10(); + return (0); +} \ No newline at end of file diff --git a/TASKS/Task 015.c b/TASKS/Task 015.c index 7cac93a..ce343ee 100644 --- a/TASKS/Task 015.c +++ b/TASKS/Task 015.c @@ -1,3 +1,5 @@ +#include + /*Write your solution after the comment Fizz-Buzz - Write a program that prints the numbers from 1 to 100, followed by a new line. But for multiples @@ -6,4 +8,24 @@ multiples of five print Buzz. For numbers which are multiples of both three and five print FizzBuzz. Your output should like this; 1 2 fizz 4 buzz fizz 7 8 fizz... and so on. -*/ \ No newline at end of file +*/ + +void fizzbuzz_game(){ + int i = 0; + + for (i = 1; i <= 100; i++){ + if (i % 3 == 0 && i % 5 == 0) + printf("FizzBuzz\t"); + else if (i % 5 == 0) + printf("Buzz\t"); + else if (i % 3 == 0) + printf("Fizz\t"); + else + printf("%d\t", i); + } +} +int main(void) +{ + fizzbuzz_game(); + return (0); +} \ No newline at end of file From ff360d357d0292e6f576e5532f77a848b18ab897 Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Fri, 27 Jan 2023 09:02:36 +0100 Subject: [PATCH 02/19] Answer to Task 16 --- TASKS/Task 016.c | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/TASKS/Task 016.c b/TASKS/Task 016.c index 8700bc0..0a608aa 100644 --- a/TASKS/Task 016.c +++ b/TASKS/Task 016.c @@ -1,3 +1,5 @@ +#include + /*Write your solution after the comment Write a recursive function that takes an integer as an argument and returns the product of all integers @@ -8,4 +10,28 @@ Output: 720 // That is 1x2x3x4x5x6 = 720 -*/ \ No newline at end of file +*/ + +int mult(int); + +int main() { + int num; + + num = 6; + printf("%d\n", mult(num)); + return 0; +} + +/** + * mult - function to recursively multiply a number till it is 1 + * @num - number to multiply till it is 1 + * Return: the recursive product + */ +int mult(int num) +{ + if (num == 1) + return (num); + if (num < 1) + return (0); + return ( num * mult(num -1)); +} From e95f2fe0d9bce4fb080ae35d2950f96a5720c748 Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Fri, 27 Jan 2023 09:09:33 +0100 Subject: [PATCH 03/19] Update Task 017.c --- TASKS/Task 017.c | 28 +++++++++++++++++++++++++++- 1 file changed, 27 insertions(+), 1 deletion(-) diff --git a/TASKS/Task 017.c b/TASKS/Task 017.c index f5ef778..a050d6a 100644 --- a/TASKS/Task 017.c +++ b/TASKS/Task 017.c @@ -1,3 +1,5 @@ +#include + /* Write a recursive function that takes an integer as an argument and returns the sum of all integers from @@ -8,4 +10,28 @@ Output: 21 // That is; 1+2+3+4+5+6 = 21 -*/ \ No newline at end of file +*/ + +int add(int); + +int main() { + int num; + + num = 6; + printf("%d\n", add(num)); + return 0; +} + +/** + * add - function to recursively add a number till it is 1 + * @num - number to add till it is 1 + * Return: the recursive sum + */ +int add(int num) +{ + if (num == 1) + return (num); + if (num < 1) + return (0); + return ( num + add(num -1)); +} From 45ac6487befbe8a11c4b625b42c0188cfd3431dc Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Fri, 27 Jan 2023 10:18:15 +0100 Subject: [PATCH 04/19] Solution to task 18 --- TASKS/Task 018.c | 27 ++++++++++++++++++++++++++- 1 file changed, 26 insertions(+), 1 deletion(-) diff --git a/TASKS/Task 018.c b/TASKS/Task 018.c index 147ff9a..9a234b2 100644 --- a/TASKS/Task 018.c +++ b/TASKS/Task 018.c @@ -1,5 +1,30 @@ +#include + /* Write a function that returns the value of x raised to the power of y. functionName(int x, int y); -*/ \ No newline at end of file +*/ + +int get_power(int x, int y) +{ + if (y < 0) + return (0); + else if (y == 0) + return (1); + else if (y == 1) + return (x); + else + return (x * get_power(x, (y - 1))); +} + +int main() { + int x, y; + + x = y = 0; + printf("Enter 2 Numbers separated by a space:\t"); + scanf("%d %d", &x, &y); + + printf("%d\n", get_power(x, y)); + return 0; +} From 1352ca5040980ab041231cbd3d99e937f5e3bb24 Mon Sep 17 00:00:00 2001 From: Sampul-CodeMine Date: Fri, 27 Jan 2023 11:01:01 +0100 Subject: [PATCH 05/19] Solution to Task 1 - 18 - Dukeson --- TASKS/Task 018.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/TASKS/Task 018.c b/TASKS/Task 018.c index 9a234b2..76a0535 100644 --- a/TASKS/Task 018.c +++ b/TASKS/Task 018.c @@ -9,7 +9,7 @@ int get_power(int x, int y) { if (y < 0) - return (0); + return ((double)(1.0/(x * get_power(x, (-1) * (y + 1))))); else if (y == 0) return (1); else if (y == 1) From 17fb40ef0fa0e93d53f2b32414286c961375811a Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Wed, 1 Feb 2023 15:29:22 +0100 Subject: [PATCH 06/19] Solution to task 19 - Dukeson --- TASKS/Task 019.c | 41 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 40 insertions(+), 1 deletion(-) diff --git a/TASKS/Task 019.c b/TASKS/Task 019.c index 5cc5874..26ea1e3 100644 --- a/TASKS/Task 019.c +++ b/TASKS/Task 019.c @@ -1,4 +1,43 @@ +#include + /* Write a function to convert temperature from Celsius to Fahrenheit and vice versa. -*/ \ No newline at end of file +*/ + +double farenheit_to_celius(double temp) +{ + double result; + + result = ((temp - 32) * 5) / 9; + return (result); +} + +double celius_to_farenheit(double temp) +{ + double result; + + result = (temp * 9 / 5) + 32; + return (result); +} + +int main(void) +{ + double num = 0; + double fah_val; + double cel_val; + + printf("Enter a Temperature in Celcius (*C):\t"); + if (scanf("%lf", &num) == 1) + { + fah_val = celius_to_farenheit(num); + printf("\nConverting %.2f celcius to fahrenheit = %.2f\n", num, fah_val); + + cel_val = farenheit_to_celius(fah_val); + printf("\nConverting %.2f fahrenheit to celcius = %.2f\n", fah_val, cel_val); + return (0); + } + printf("\nYou did not enter a numeric data.\n"); + return (1); + +} \ No newline at end of file From e49f4da46a9cf2edcd06e7bd92100c73b249a57f Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Wed, 1 Feb 2023 15:32:52 +0100 Subject: [PATCH 07/19] Solution to task 19 - Dukeson --- TASKS/Task 019.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/TASKS/Task 019.c b/TASKS/Task 019.c index 26ea1e3..dbb85f2 100644 --- a/TASKS/Task 019.c +++ b/TASKS/Task 019.c @@ -5,6 +5,12 @@ Fahrenheit and vice versa. */ +/** + * farenheit_to_celius - convert Fahrenheit temperature to Celcius + * @temp: temperature value in celcius (double) + * Return: The Fahrenheit value after computation/conversion + */ + double farenheit_to_celius(double temp) { double result; @@ -13,6 +19,12 @@ double farenheit_to_celius(double temp) return (result); } +/** + * farenheit_to_celius - convert Celcius temperature to Fahrenheit + * @temp: temperature value in fahrenheit (double) + * Return: The Celcius value after computation/conversion + */ + double celius_to_farenheit(double temp) { double result; From 0bf6c54994b0c0a8c0cbce8898b07e074867260f Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Wed, 1 Feb 2023 18:18:23 +0100 Subject: [PATCH 08/19] Solution to some of the task --- TASKS/dukeson_solution/task1.c | 19 ++++++++++++++++ TASKS/dukeson_solution/task10.c | 0 TASKS/dukeson_solution/task11.c | 0 TASKS/dukeson_solution/task12.c | 0 TASKS/dukeson_solution/task13.c | 0 TASKS/dukeson_solution/task14.c | 0 TASKS/dukeson_solution/task15.c | 0 TASKS/dukeson_solution/task16.c | 0 TASKS/dukeson_solution/task17.c | 0 TASKS/dukeson_solution/task18.c | 0 TASKS/dukeson_solution/task19.c | 0 TASKS/dukeson_solution/task2.c | 19 ++++++++++++++++ TASKS/dukeson_solution/task20.c | 0 TASKS/dukeson_solution/task21.c | 0 TASKS/dukeson_solution/task22.c | 0 TASKS/dukeson_solution/task23.c | 0 TASKS/dukeson_solution/task24.c | 0 TASKS/dukeson_solution/task25.c | 0 TASKS/dukeson_solution/task26.c | 0 TASKS/dukeson_solution/task27.c | 0 TASKS/dukeson_solution/task28.c | 0 TASKS/dukeson_solution/task29.c | 0 TASKS/dukeson_solution/task3.c | 24 ++++++++++++++++++++ TASKS/dukeson_solution/task30.c | 0 TASKS/dukeson_solution/task31.c | 0 TASKS/dukeson_solution/task32.c | 0 TASKS/dukeson_solution/task33.c | 0 TASKS/dukeson_solution/task34.c | 0 TASKS/dukeson_solution/task4.c | 24 ++++++++++++++++++++ TASKS/dukeson_solution/task5.c | 0 TASKS/dukeson_solution/task6.c | 0 TASKS/dukeson_solution/task7.c | 0 TASKS/dukeson_solution/task8.c | 0 TASKS/dukeson_solution/task9.c | 0 TASKS/dukeson_solution/task_list.md | 34 +++++++++++++++++++++++++++++ 35 files changed, 120 insertions(+) create mode 100644 TASKS/dukeson_solution/task1.c create mode 100644 TASKS/dukeson_solution/task10.c create mode 100644 TASKS/dukeson_solution/task11.c create mode 100644 TASKS/dukeson_solution/task12.c create mode 100644 TASKS/dukeson_solution/task13.c create mode 100644 TASKS/dukeson_solution/task14.c create mode 100644 TASKS/dukeson_solution/task15.c create mode 100644 TASKS/dukeson_solution/task16.c create mode 100644 TASKS/dukeson_solution/task17.c create mode 100644 TASKS/dukeson_solution/task18.c create mode 100644 TASKS/dukeson_solution/task19.c create mode 100644 TASKS/dukeson_solution/task2.c create mode 100644 TASKS/dukeson_solution/task20.c create mode 100644 TASKS/dukeson_solution/task21.c create mode 100644 TASKS/dukeson_solution/task22.c create mode 100644 TASKS/dukeson_solution/task23.c create mode 100644 TASKS/dukeson_solution/task24.c create mode 100644 TASKS/dukeson_solution/task25.c create mode 100644 TASKS/dukeson_solution/task26.c create mode 100644 TASKS/dukeson_solution/task27.c create mode 100644 TASKS/dukeson_solution/task28.c create mode 100644 TASKS/dukeson_solution/task29.c create mode 100644 TASKS/dukeson_solution/task3.c create mode 100644 TASKS/dukeson_solution/task30.c create mode 100644 TASKS/dukeson_solution/task31.c create mode 100644 TASKS/dukeson_solution/task32.c create mode 100644 TASKS/dukeson_solution/task33.c create mode 100644 TASKS/dukeson_solution/task34.c create mode 100644 TASKS/dukeson_solution/task4.c create mode 100644 TASKS/dukeson_solution/task5.c create mode 100644 TASKS/dukeson_solution/task6.c create mode 100644 TASKS/dukeson_solution/task7.c create mode 100644 TASKS/dukeson_solution/task8.c create mode 100644 TASKS/dukeson_solution/task9.c create mode 100644 TASKS/dukeson_solution/task_list.md diff --git a/TASKS/dukeson_solution/task1.c b/TASKS/dukeson_solution/task1.c new file mode 100644 index 0000000..db0c1ea --- /dev/null +++ b/TASKS/dukeson_solution/task1.c @@ -0,0 +1,19 @@ +#include + +/* function to find the sum of two numbers */ + +double sum_finder(int first, int second) +{ + return (first + second); +} + +int main(void) +{ + int first = 0, second = 0; + + printf("Enter two (2) numbers separated with a space:\t"); + scanf("%i %i", &first, &second); + printf("The sum of %d and %d = %.2f\n", first, second, sum_finder(first, second)); + + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task10.c b/TASKS/dukeson_solution/task10.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task11.c b/TASKS/dukeson_solution/task11.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task12.c b/TASKS/dukeson_solution/task12.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task13.c b/TASKS/dukeson_solution/task13.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task14.c b/TASKS/dukeson_solution/task14.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task15.c b/TASKS/dukeson_solution/task15.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task16.c b/TASKS/dukeson_solution/task16.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task17.c b/TASKS/dukeson_solution/task17.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task18.c b/TASKS/dukeson_solution/task18.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task19.c b/TASKS/dukeson_solution/task19.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task2.c b/TASKS/dukeson_solution/task2.c new file mode 100644 index 0000000..1527cee --- /dev/null +++ b/TASKS/dukeson_solution/task2.c @@ -0,0 +1,19 @@ +#include + +/* Write a function to find the largest of two numbers */ + +int get_largest(int a, int b) +{ + return ((a > b) ? a : b); +} + +int main(void) +{ + int first = 0, second = 0; + + printf("Enter two (2) numbers separated with a space:\t"); + scanf("%i %i", &first, &second); + printf("The larger of %d and %d is %d\n", first, second, get_largest(first, second)); + + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task20.c b/TASKS/dukeson_solution/task20.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task21.c b/TASKS/dukeson_solution/task21.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task22.c b/TASKS/dukeson_solution/task22.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task23.c b/TASKS/dukeson_solution/task23.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task24.c b/TASKS/dukeson_solution/task24.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task25.c b/TASKS/dukeson_solution/task25.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task26.c b/TASKS/dukeson_solution/task26.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task27.c b/TASKS/dukeson_solution/task27.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task28.c b/TASKS/dukeson_solution/task28.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task29.c b/TASKS/dukeson_solution/task29.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task3.c b/TASKS/dukeson_solution/task3.c new file mode 100644 index 0000000..46a8763 --- /dev/null +++ b/TASKS/dukeson_solution/task3.c @@ -0,0 +1,24 @@ +#include + +/* Write a function to find the factorial of a number */ + +int get_factorial(int a) +{ + if (a == 0) + return (1); + if (a == 1) + return (a); + return (a * get_factorial(a - 1)); +} + +int main(void) +{ + int num = 0; + + printf("Enter a number:\t"); + if (scanf("%i", &num) == 1) + printf("%d! is %d\n", num, get_factorial(num)); + else + printf("\nYou did not provide a numeric data.\n"); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task30.c b/TASKS/dukeson_solution/task30.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task31.c b/TASKS/dukeson_solution/task31.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task32.c b/TASKS/dukeson_solution/task32.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task33.c b/TASKS/dukeson_solution/task33.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task34.c b/TASKS/dukeson_solution/task34.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task4.c b/TASKS/dukeson_solution/task4.c new file mode 100644 index 0000000..3334b27 --- /dev/null +++ b/TASKS/dukeson_solution/task4.c @@ -0,0 +1,24 @@ +#include + +/* Write a function to check if a number is even or odd */ + +void odd_even(int num) +{ + printf("%s",(num % 2 == 0) ? "Even" : "Odd"); +} + +int main(void) +{ + int num = 0; + + printf("Enter a number:\t"); + if (scanf("%i", &num) == 1) + { + printf("%d is an ", num); + odd_even(num); + printf(" number\n"); + } + else + printf("\nYou did not provide a numeric data.\n"); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task5.c b/TASKS/dukeson_solution/task5.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task6.c b/TASKS/dukeson_solution/task6.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task7.c b/TASKS/dukeson_solution/task7.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task8.c b/TASKS/dukeson_solution/task8.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task9.c b/TASKS/dukeson_solution/task9.c new file mode 100644 index 0000000..e69de29 diff --git a/TASKS/dukeson_solution/task_list.md b/TASKS/dukeson_solution/task_list.md new file mode 100644 index 0000000..6444e23 --- /dev/null +++ b/TASKS/dukeson_solution/task_list.md @@ -0,0 +1,34 @@ +Write a function to find the sum of two numbers +Write a function to find the largest of two numbers +Write a function to find the factorial of a number +Write a function to check if a number is even or odd +Write a function to find the GCD (greatest common divisor) of two numbers +Write a function to find the LCM (least common multiple) of two numbers +Write a function to find the area of a circle +Write a function to find the volume of a sphere +Write a function to find the Fibonacci series of a given number +Write a function to convert temperature from Celsius to Fahrenheit and vice versa. +Write a program that implements different mathematical functions such as finding the factorial of a number, calculating the power of a number, and finding the square root of a number. +Write a program that implements functions to perform string operations, such as concatenating two strings, finding the length of a string, and reversing a string. +Write a program that implements functions to perform operations on arrays, such as finding the largest and smallest elements in an array, sorting an array in ascending or descending order, and finding the average of all elements in an array. +Write a program that implements functions to perform operations on structures, such as finding the largest and smallest elements in a structure, sorting a structure in ascending or descending order, and finding the average of all elements in a structure. +Create a program to calculate the factorial of a number. +Write a program to find the largest and smallest number in an array. +Create a program to sort an array of numbers in ascending or descending order. +Write a program to reverse a string. +Create a program to check if a number is prime or not. +Write a program to find the sum of all elements in an array. +Create a program to find the average of a set of numbers. +Write a program to find the frequency of each character in a string. +Create a program to convert a decimal number to binary, octal, or hexadecimal. +Write a program to check if a string is a palindrome. +Write a program to implement the QuickSort algorithm. +Create a program to implement the MergeSort algorithm. +Write a program to find the Longest Common Subsequence (LCS) of two strings. +Create a program to find the shortest path in a graph using Dijkstra's algorithm. +Write a program to implement the Binary Search algorithm. +Create a program to find the minimum number of coins needed to make a certain amount of change. +Write a program to implement the Knapsack problem. +Create a program to implement the Prim's algorithm for finding the minimum spanning tree in a graph. +Write a program to implement the Tower of Hanoi puzzle. +Create a program to implement the Depth-First Search (DFS) algorithm for graph traversal. \ No newline at end of file From 05467a9f64f6ac5940d70762ef0f3b5387b21ceb Mon Sep 17 00:00:00 2001 From: Sampul-CodeMine Date: Thu, 2 Feb 2023 08:07:28 +0100 Subject: [PATCH 09/19] ,Solution task - Dukeson --- TASKS/dukeson_solution/task5.c | 36 ++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/TASKS/dukeson_solution/task5.c b/TASKS/dukeson_solution/task5.c index e69de29..84a1905 100644 --- a/TASKS/dukeson_solution/task5.c +++ b/TASKS/dukeson_solution/task5.c @@ -0,0 +1,36 @@ +#include + +/* Write a function to find the GCD (greatest common divisor) of two numbers */ + +int gcd_one(int num_one, int num_two) +{ + if (num_two != 0) + return (gcd_one(num_two, num_one % num_two)); + else + return (num_one); +} + +int gcd_two(int numone, int numtwo) +{ + int i = 0; + int gcd = 0; + + for(i = 1; i <= numone && i <= numtwo; ++i) + { + if(numone % i == 0 && numtwo % i == 0) + gcd = i; + } + return (gcd); +} + +int main(void) +{ + int first = 0, second = 0; + + printf("Enter two (2) numbers separated with a space:\t"); + scanf("%i %i", &first, &second); + printf("\n\nFIRST METHOD\n"); + printf("Greatest Common Divisor of %d and %d:\t %d", first, second, gcd_two(first, second)); + printf("\n\nRECURSIVE METHOD\n"); + printf("Greatest Common Divisor of %d and %d:\t %d", first, second, gcd_one(first, second)); +} From 2dbd32407bdc1f3a49bef0ea6469161a864758c4 Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Sat, 4 Feb 2023 16:51:43 +0100 Subject: [PATCH 10/19] Some of the solution to the task - Dukeson --- TASKS/dukeson_solution/task10.c | 54 +++++++++++++++++++++++++++++++++ TASKS/dukeson_solution/task6.c | 26 ++++++++++++++++ TASKS/dukeson_solution/task7.c | 22 ++++++++++++++ TASKS/dukeson_solution/task8.c | 22 ++++++++++++++ TASKS/dukeson_solution/task9.c | 39 ++++++++++++++++++++++++ 5 files changed, 163 insertions(+) diff --git a/TASKS/dukeson_solution/task10.c b/TASKS/dukeson_solution/task10.c index e69de29..2fe53b2 100644 --- a/TASKS/dukeson_solution/task10.c +++ b/TASKS/dukeson_solution/task10.c @@ -0,0 +1,54 @@ +#include + +/* + Write a function to convert temperature from Celsius to + Fahrenheit and vice versa. +*/ + +/** + * farenheit_to_celius - convert Fahrenheit temperature to Celcius + * @temp: temperature value in celcius (double) + * Return: The Fahrenheit value after computation/conversion + */ + +double farenheit_to_celius(double temp) +{ + double result; + + result = ((temp - 32) * 5) / 9; + return (result); +} + +/** + * farenheit_to_celius - convert Celcius temperature to Fahrenheit + * @temp: temperature value in fahrenheit (double) + * Return: The Celcius value after computation/conversion + */ + +double celius_to_farenheit(double temp) +{ + double result; + + result = (temp * 9 / 5) + 32; + return (result); +} + +int main(void) +{ + double num = 0; + double fah_val; + double cel_val; + + printf("Enter a Temperature in Celcius (*C):\t"); + if (scanf("%lf", &num) == 1) + { + fah_val = celius_to_farenheit(num); + printf("\nConverting %.2f celcius to fahrenheit = %.2f\n", num, fah_val); + + cel_val = farenheit_to_celius(fah_val); + printf("\nConverting %.2f fahrenheit to celcius = %.2f\n", fah_val, cel_val); + return (0); + } + printf("\nYou did not enter a numeric data.\n"); + return (1); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task6.c b/TASKS/dukeson_solution/task6.c index e69de29..5b628e8 100644 --- a/TASKS/dukeson_solution/task6.c +++ b/TASKS/dukeson_solution/task6.c @@ -0,0 +1,26 @@ +#include + +/* Write a function to find the LCM (least common multiple) of two numbers */ + +int get_lcm(int num_one, int num_two) +{ + int biggest = (num_one > num_two) ? num_one : num_two; + + while (1) + { + if (((biggest % num_one) == 0) && ((biggest % num_two) == 0)) + return (biggest); + biggest++; + } + return (0); +} + +int main(void) +{ + int first = 0, second = 0; + + printf("Enter two (2) numbers separated with a space:\t"); + scanf("%i %i", &first, &second); + printf("The LCM of %d and %d = %d\n", first, second, get_lcm(first, second)); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task7.c b/TASKS/dukeson_solution/task7.c index e69de29..757e2a6 100644 --- a/TASKS/dukeson_solution/task7.c +++ b/TASKS/dukeson_solution/task7.c @@ -0,0 +1,22 @@ +#include + +#define PI 3.14159 + +/* Write a function to find the area of a circle */ + +double get_circle_area(int radius) +{ + if (radius > 0) + return ((double)(PI * (radius * radius))); + return (0.0); +} + +int main(void) +{ + int rad = 0; + + printf("Enter the radius:\t"); + if (scanf("%i", &rad)) + printf("The area of a circle with radius of %d = %.2f\n", rad, get_circle_area(rad)); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task8.c b/TASKS/dukeson_solution/task8.c index e69de29..63e6673 100644 --- a/TASKS/dukeson_solution/task8.c +++ b/TASKS/dukeson_solution/task8.c @@ -0,0 +1,22 @@ +#include + +#define PI 3.14159 + +/* Write a function to find the volume of a sphere */ + +double sphere_volume(int radius) +{ + if (radius > 0) + return ((double)(4 * (PI * (radius * radius * radius))) / 3); + return (0.0); +} + +int main(void) +{ + int rad = 0; + + printf("Enter the radius:\t"); + if (scanf("%i", &rad)) + printf("The volume of a sphere with radius of %d = %.2f\n", rad, sphere_volume(rad)); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task9.c b/TASKS/dukeson_solution/task9.c index e69de29..65e11fb 100644 --- a/TASKS/dukeson_solution/task9.c +++ b/TASKS/dukeson_solution/task9.c @@ -0,0 +1,39 @@ +#include + +/* Write a function to find the Fibonacci series of a given number */ +void print_fibo_series(int num) +{ + int temp; + int swp_1 = 0, swp_2 = 1; + int itr = 0; + + if (num >= 2) + { + printf("%d %d ", swp_1, swp_2); + while (itr < num) + { + temp = swp_1 + swp_2; + printf("%d ", temp); + swp_1 = swp_2; + swp_2 = temp; + ++itr; + } + } + else + { + printf("%d", swp_1); + } +} + +int main(void) +{ + int num = 0; + + printf("Enter the radius:\t"); + if (scanf("%i", &num)) + { + printf("Fibonnaci series for %d = ", num); + print_fibo_series(num); + } + return (0); +} \ No newline at end of file From c4a79ef2f829950381472562df2476a418a870bb Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Sat, 4 Feb 2023 18:14:09 +0100 Subject: [PATCH 11/19] Some solution to the task given - Dukeson --- TASKS/dukeson_solution/task11.c | 21 +++++++++++++++++++ TASKS/dukeson_solution/task12.c | 37 +++++++++++++++++++++++++++++++++ TASKS/dukeson_solution/task13.c | 36 ++++++++++++++++++++++++++++++++ TASKS/dukeson_solution/task14.c | 0 TASKS/dukeson_solution/task15.c | 0 TASKS/dukeson_solution/task16.c | 0 TASKS/dukeson_solution/task17.c | 0 TASKS/dukeson_solution/task18.c | 0 TASKS/dukeson_solution/task19.c | 0 TASKS/dukeson_solution/task20.c | 0 TASKS/dukeson_solution/task21.c | 0 TASKS/dukeson_solution/task22.c | 0 TASKS/dukeson_solution/task23.c | 0 TASKS/dukeson_solution/task24.c | 0 TASKS/dukeson_solution/task25.c | 0 TASKS/dukeson_solution/task26.c | 0 TASKS/dukeson_solution/task27.c | 0 TASKS/dukeson_solution/task28.c | 0 TASKS/dukeson_solution/task29.c | 0 TASKS/dukeson_solution/task30.c | 0 TASKS/dukeson_solution/task31.c | 0 TASKS/dukeson_solution/task32.c | 0 TASKS/dukeson_solution/task33.c | 0 TASKS/dukeson_solution/task34.c | 0 24 files changed, 94 insertions(+) delete mode 100644 TASKS/dukeson_solution/task14.c delete mode 100644 TASKS/dukeson_solution/task15.c delete mode 100644 TASKS/dukeson_solution/task16.c delete mode 100644 TASKS/dukeson_solution/task17.c delete mode 100644 TASKS/dukeson_solution/task18.c delete mode 100644 TASKS/dukeson_solution/task19.c delete mode 100644 TASKS/dukeson_solution/task20.c delete mode 100644 TASKS/dukeson_solution/task21.c delete mode 100644 TASKS/dukeson_solution/task22.c delete mode 100644 TASKS/dukeson_solution/task23.c delete mode 100644 TASKS/dukeson_solution/task24.c delete mode 100644 TASKS/dukeson_solution/task25.c delete mode 100644 TASKS/dukeson_solution/task26.c delete mode 100644 TASKS/dukeson_solution/task27.c delete mode 100644 TASKS/dukeson_solution/task28.c delete mode 100644 TASKS/dukeson_solution/task29.c delete mode 100644 TASKS/dukeson_solution/task30.c delete mode 100644 TASKS/dukeson_solution/task31.c delete mode 100644 TASKS/dukeson_solution/task32.c delete mode 100644 TASKS/dukeson_solution/task33.c delete mode 100644 TASKS/dukeson_solution/task34.c diff --git a/TASKS/dukeson_solution/task11.c b/TASKS/dukeson_solution/task11.c index e69de29..e7620a6 100644 --- a/TASKS/dukeson_solution/task11.c +++ b/TASKS/dukeson_solution/task11.c @@ -0,0 +1,21 @@ +#include + +/* Create a program to calculate the factorial of a number. */ +int factorial(int num) +{ + if (num == 0) + return (1); + if (num == 1) + return (num); + return (num * factorial(num - 1)); +} + +int main(void) +{ + int num = 0; + + printf("Enter the number:\t"); + if (scanf("%i", &num)) + printf("The factorial of %d! = %d\n", num, factorial(num)); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task12.c b/TASKS/dukeson_solution/task12.c index e69de29..9e6577d 100644 --- a/TASKS/dukeson_solution/task12.c +++ b/TASKS/dukeson_solution/task12.c @@ -0,0 +1,37 @@ +#include +#include + +/* Create a program to check if a number is prime or not.. */ +void is_prime(int num) +{ + int itr = 0; + int flag = 0; + + if (num == 0 || num == 1) + flag = 1; + + for (itr = 2; itr <= (num / 2); itr++) + { + if (num % itr == 0) + { + flag = 1; + break; + } + } + if (flag == 0) + printf("%d is a prime number\n", num); + else + printf("%d is NOT a prime number\n", num); +} + +int main(void) +{ + int num = 0; + + printf("Enter the number:\t"); + if (scanf("%i", &num)) + { + is_prime(num); + } + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task13.c b/TASKS/dukeson_solution/task13.c index e69de29..77abfb5 100644 --- a/TASKS/dukeson_solution/task13.c +++ b/TASKS/dukeson_solution/task13.c @@ -0,0 +1,36 @@ +#include +#include + +/* Write a program to find the sum of all elements in an array. */ + + +int sum_array(int argc, char *argv[]) +{ + int i = 1; + int sum = 0; + + for (i = 1; i <= argc; i++) + { + sum += atoi(argv[i]); + } + return (sum); +} + +int main(int argc, char *argv[]) +{ + int i = 1; + if (argc > 1) + { + printf("The sum of the array ["); + for (i = 1; i < argc; i++) + { + printf("%d", atoi(argv[i])); + if (i < (argc - 1)) + printf(", "); + } + printf("] = %d", sum_array(argc, argv)); + } + else + printf("Please enter some numeric data along side your program name."); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task14.c b/TASKS/dukeson_solution/task14.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task15.c b/TASKS/dukeson_solution/task15.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task16.c b/TASKS/dukeson_solution/task16.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task17.c b/TASKS/dukeson_solution/task17.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task18.c b/TASKS/dukeson_solution/task18.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task19.c b/TASKS/dukeson_solution/task19.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task20.c b/TASKS/dukeson_solution/task20.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task21.c b/TASKS/dukeson_solution/task21.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task22.c b/TASKS/dukeson_solution/task22.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task23.c b/TASKS/dukeson_solution/task23.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task24.c b/TASKS/dukeson_solution/task24.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task25.c b/TASKS/dukeson_solution/task25.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task26.c b/TASKS/dukeson_solution/task26.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task27.c b/TASKS/dukeson_solution/task27.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task28.c b/TASKS/dukeson_solution/task28.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task29.c b/TASKS/dukeson_solution/task29.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task30.c b/TASKS/dukeson_solution/task30.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task31.c b/TASKS/dukeson_solution/task31.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task32.c b/TASKS/dukeson_solution/task32.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task33.c b/TASKS/dukeson_solution/task33.c deleted file mode 100644 index e69de29..0000000 diff --git a/TASKS/dukeson_solution/task34.c b/TASKS/dukeson_solution/task34.c deleted file mode 100644 index e69de29..0000000 From b0e715d4e516ba0bca38bfc0c2cc9a112770ad09 Mon Sep 17 00:00:00 2001 From: Sampul-CodeMine Date: Sat, 4 Feb 2023 20:40:28 +0100 Subject: [PATCH 12/19] ,Solution to task - Dukeson --- TASKS/Task-21-Pointers-Quiz.md | 66 ++++++++++++++++++++++++++++++++- TASKS/Task-22.c | 16 +++++++- TASKS/Task-23.c | 22 ++++++++++- TASKS/Task-24.c | 14 ++++++- TASKS/Task-25.c | 28 +++++++++++++- TASKS/a.out | Bin 0 -> 4260 bytes TASKS/core | 0 7 files changed, 141 insertions(+), 5 deletions(-) create mode 100755 TASKS/a.out create mode 100644 TASKS/core diff --git a/TASKS/Task-21-Pointers-Quiz.md b/TASKS/Task-21-Pointers-Quiz.md index 9f783c2..331df51 100644 --- a/TASKS/Task-21-Pointers-Quiz.md +++ b/TASKS/Task-21-Pointers-Quiz.md @@ -1,17 +1,81 @@ What is the purpose of pointers in C programming languages? +ANS +=== + +Pointers are useful datatypes. A pointer holds the address of a variable through which the variable being pointed to can be directly manipulated. Both pointer variable and the variable being pointed to must be of the same datatype. + What is the difference between a pointer and a regular variable in C programming languages? +ANS +=== + +The major difference between a regular variable and a pointer variable is that a regular variable passes data by the value stored in it while the pointer passes data by referencing the address of the variable being pointed to. + How do you declare a pointer in C programming languages? +ANS +=== + +To declare a pointer in C programming language, + datatype * pointername; +e.g int * ptr; +To avoid gibberish values it is good to initialize your pointer +int * ptr = NULL; +but to make it point to a variable or memory location +int * ptr = &variablename; + How do you access the value stored at the memory address pointed by a pointer in C programming languages? +ANS +=== + +You maken use of the asterisk +e.g +int * ptr = # +printf("%d", *ptr); // this will print the value in num; + What is a null pointer in C programming languages? +ANS +=== + +Null pointers are pointers thst have been declared but not pointing to a particular memory location or address. They are initialized with the value NULL. + How do you declare pointers to pointers in C programming languages? +ANS +=== + +You declare pointer to pointers using double asterisks +e.g +int **ptr; + What is the relationship between pointers and arrays in C programming languages? +ANS +=== + +The relationship between a pointer and an array is that both hold addresses to a location or memory space. +A pointer holds the address of the variable it is pointing to while the arrayname serves as a pointer to the memory space it has been allocated to keep for a particular size of element of the same datatype. + What is dynamic memory allocation in C programming languages and how is it achieved using pointers? -How do you deallocate dynamically allocated memory in C programming languages? \ No newline at end of file +ANS +=== + +Dynamic allocation of memory is allocating memory at the time of execution (run time). The functions calloc() and malloc() support allocating of dynamic memory. + +How do you deallocate dynamically allocated memory in C programming languages? + +ANS +=== + +We dynamically allocate memory using the following +malloc, calloc, and realloc functiins. + +to use malloc +variable = malloc(sizeof(datatype)); +You have to free up the memory using the free function +e.g +free(variable); diff --git a/TASKS/Task-22.c b/TASKS/Task-22.c index 8cd01c4..e7cd756 100644 --- a/TASKS/Task-22.c +++ b/TASKS/Task-22.c @@ -2,4 +2,18 @@ Create a program that declares a pointer to an integer, assigns an address to it, and outputs the value stored at the memory address pointed by the pointer. -*/ \ No newline at end of file +*/ +#include +int main(void) +{ + int num = 123; + int *ptr = NULL; + + printf("Number is :\t%d\n", num); + + ptr = # + + printf("Value in the variable pointed to by the pointer is %d\n", *ptr); + + return (0); +} diff --git a/TASKS/Task-23.c b/TASKS/Task-23.c index dfddb16..544a7b4 100644 --- a/TASKS/Task-23.c +++ b/TASKS/Task-23.c @@ -1,4 +1,24 @@ /* Create a program that uses pointers to find the maximum value stored in an array. -*/ \ No newline at end of file +*/ +#include + +int main(void) +{ + int num[] = {12, 32, 2, 8, 10, 405, 7, 15, 35, 117}; + int max = 0, len = 0; + int itr; + int *ptr = num; + + len = sizeof(num) / sizeof(num[0]); + max = num[0]; + for (itr = 1; itr < len; itr++) + { + printf("max: %d\tptr: %d\n", max, *(ptr + itr)); + if (*(ptr + itr) > max) + max = *(ptr + itr); + } + printf("The biggest integer in the array is %d\n", max); + return 0; +} diff --git a/TASKS/Task-24.c b/TASKS/Task-24.c index 79d1c16..e8ce413 100644 --- a/TASKS/Task-24.c +++ b/TASKS/Task-24.c @@ -1,4 +1,16 @@ /* Create a program that demonstrates the use of pointers to pass information between functions. -*/ \ No newline at end of file +*/ + +#include + +int sum_total(int *tsum, int num) +{ +} + +int main(void) +{ + int sum_total = 0; + int sum = 0; +} diff --git a/TASKS/Task-25.c b/TASKS/Task-25.c index e2aa2a5..33defb4 100644 --- a/TASKS/Task-25.c +++ b/TASKS/Task-25.c @@ -1,3 +1,29 @@ /* Declare two integer variables and swap their values using a pointer. -*/ \ No newline at end of file +*/ +#include + +void swapper(int *n, int *m) +{ + int temp; + + temp = *n; + *n = *m; + *m = temp; +} + +int main(void) +{ + int n_one; + int n_two; + + printf("Enter two (2) numbers separated by a space:\t"); + scanf("%d %d", &n_one, &n_two); + printf("Before Swap\n"); + printf("Number 1:\t%d\nNumber 2:\t%d\n", n_one, n_two); + swapper(&n_one, &n_two); + printf("After Swap\n"); + printf("Number 1:\t%d\nNumber 2:\t%d\n", n_one, n_two); + + return (0); +} diff --git a/TASKS/a.out b/TASKS/a.out new file mode 100755 index 0000000000000000000000000000000000000000..a09b8b8773ea381b421dd020d52f6566a4b341c8 GIT binary patch literal 4260 zcmbVPU2Ggz6+W}xq)xI)HX)^LXsbz-1_zSavAzBad9a%_#KMV!iBKyQjc0ep-XXg? ztJ!g|MFoiFp$`d(sz@M2@JdLiMU|-dk$4CQUMj>3eW(O)_=jymf>0s~;-e1S{M>u)o%^?6es1QZrfH(6PX>hOy$^{LA+P1|FC&|ZqRTe;_R8b387BG^ z&mn=Fg^kf%AJ4F}5!4hPJ(nM2PqH;KMzbi!J`+JZZwpup}ZXZ^uW2_Y(wi3imP9+1J5p1UA^IBM6RQU zzFu06T(KoeWSYpEtqoaiZETm;TBp;wEvJtBVf&k{wfx(s*UkJ&J8NEE*YYbjbNS2d z1Hjb#p+A}ES?H2)ZRGWpc1B;hIU;gr5+8RQY=RH)L(AEXr#l5L-zlsib}c6>?HuAo zuB>MCE35eKw^z}5em~Z|xzg@4udIF?wtwwIYN{TfjjU{Ie-W}@&~JnIosZDt;s7tz4hBabvnNX!xm9?^+;RZy|S*|{@Qx= z-p|_a^pLy-->)vMpSyP>@+o|(2OsOfW`Z%qsIOl66ndWobL~2b!8jJ9xPKsy=LXl`CHS#yB0p4VVBPG2WbS70B%IqIxu3Xi-T~%v zsDc0Te#gH7tV8Fyx(||dJOQo%e7|VRNd5y)S ziGxdVxoX!J^b2m#^!&O$IAWN_m^$qAf$`#mIXE_cSTEU4EN?^v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i%Q}7t<~XAI4x&aRsoG)g&ht-FaeTWq5XX0xA~lX*z`%CdUi2FmamvS7rN0H8 z{hBm__?wtEMf8z>4MtlHWuL_Wjwt}i7}D>+TvLj!BCZ7k--!Fb?3d%Z31)4IOl*$7 VD*&n5y9YfTcL Date: Sun, 5 Feb 2023 01:54:56 +0100 Subject: [PATCH 13/19] ,Solution to task - Dukeson --- TASKS/Task-24.c | 35 ++++++++++++++++++++++++++++++++--- TASKS/a.out | Bin 4260 -> 0 bytes 2 files changed, 32 insertions(+), 3 deletions(-) delete mode 100755 TASKS/a.out diff --git a/TASKS/Task-24.c b/TASKS/Task-24.c index e8ce413..64b2a23 100644 --- a/TASKS/Task-24.c +++ b/TASKS/Task-24.c @@ -5,12 +5,41 @@ information between functions. #include -int sum_total(int *tsum, int num) +int sum_total(int *tsum, int num, int num2) { + int sum = 0; + + sum = num + num2; + *tsum += sum; + return (sum); +} + +int accept_val(char *str) +{ + int num = 0; + printf("Enter %s:\t", str); + if (scanf("%d", &num) == 1) + return (num); + return (0); } int main(void) { - int sum_total = 0; - int sum = 0; + int sum_all = 0; + int itr = 0; + int n1, n2, sum; + int itrsize = 0; + + itrsize = accept_val("Loop Size"); + printf("\n"); + for (itr = 1; itr <= itrsize; itr++) + { + sum = 0; + n1 = n2 = 0; + n1 = accept_val("First Number"); + n2 = accept_val("Second Number"); + sum = sum_total(&sum_all, n1, n2); + printf("\n%d + %d = %d\n", n1, n2, sum); + } + printf("\nOverall Sum is %d\n", sum_all); } diff --git a/TASKS/a.out b/TASKS/a.out deleted file mode 100755 index a09b8b8773ea381b421dd020d52f6566a4b341c8..0000000000000000000000000000000000000000 GIT binary patch literal 0 HcmV?d00001 literal 4260 zcmbVPU2Ggz6+W}xq)xI)HX)^LXsbz-1_zSavAzBad9a%_#KMV!iBKyQjc0ep-XXg? ztJ!g|MFoiFp$`d(sz@M2@JdLiMU|-dk$4CQUMj>3eW(O)_=jymf>0s~;-e1S{M>u)o%^?6es1QZrfH(6PX>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ph* zS!sqrti@8wL0H1$p>CArfNhv!HA6cHts0IGIp7$Bv<^`lrdFgjBAg^EnItQoq{tMF zDbi4*8;7}dN9xXbOHCa0(xO*&ta^0u%Q?Gw{>adfDj?|;9ihYj{Xed;=RI_C`pmR7 zH9I@?f@Q%4bS?$Y&OY~mB^sZVJfN%!#!|)W=?j6~Xy9GieOEp3$a0!~5-E+a61cXb zo?DjnkO!D`;)OF)r>BprwfO%?E=@9zlk{&5m8+KS78o8$;?i$&7010n;@Qdjk?l?5 zANeeF=CUouaUXJf@}6TH?>;i`QQo;E+Q~y;-iy?EHGl9+3jEh3j(0GbZ+q3A zs_#>Y4esdf=KamPTag+s&t#67aeOn7b?E8#c(=a@Mo#0akPe*W0q8u7Nvhuk=xpy< zFy9zt9Xdq!cOBbnfLQ~_{RW)mPeNBjA9*Q}e3L}K@er4#BO%rAmw;(zTy$n{5}Bi( z5WfZKWiWL#6aOYe9P3e}+Itm-9bm@sjI2B)?%VM1OyYR9HXai9J;bm!wio@DMBFXt z{Jtdi%Q}7t<~XAI4x&aRsoG)g&ht-FaeTWq5XX0xA~lX*z`%CdUi2FmamvS7rN0H8 z{hBm__?wtEMf8z>4MtlHWuL_Wjwt}i7}D>+TvLj!BCZ7k--!Fb?3d%Z31)4IOl*$7 VD*&n5y9YfTcL Date: Sun, 5 Feb 2023 02:19:07 +0100 Subject: [PATCH 14/19] Updated - Dukeson --- TASKS/Task-21-Pointers-Quiz.md | 42 +++++++++++++++++++++------------- 1 file changed, 26 insertions(+), 16 deletions(-) diff --git a/TASKS/Task-21-Pointers-Quiz.md b/TASKS/Task-21-Pointers-Quiz.md index 331df51..4215489 100644 --- a/TASKS/Task-21-Pointers-Quiz.md +++ b/TASKS/Task-21-Pointers-Quiz.md @@ -1,9 +1,9 @@ What is the purpose of pointers in C programming languages? -ANS +ANSWER === -Pointers are useful datatypes. A pointer holds the address of a variable through which the variable being pointed to can be directly manipulated. Both pointer variable and the variable being pointed to must be of the same datatype. +Pointers are useful resources. A pointer holds the address of a variable through which the variable being pointed to can be directly manipulated. Both pointer variable and the variable being pointed to must be of the same datatype. What is the difference between a pointer and a regular variable in C programming languages? @@ -11,6 +11,7 @@ ANS === The major difference between a regular variable and a pointer variable is that a regular variable passes data by the value stored in it while the pointer passes data by referencing the address of the variable being pointed to. +--- How do you declare a pointer in C programming languages? @@ -18,12 +19,19 @@ ANS === To declare a pointer in C programming language, - datatype * pointername; -e.g int * ptr; -To avoid gibberish values it is good to initialize your pointer -int * ptr = NULL; + +`datatype * pointername;` + +e.g `int * ptr;` + +To avoid gibberish values it is good to initialize your pointer: + +`int * ptr = NULL;` + but to make it point to a variable or memory location -int * ptr = &variablename; + +`int * ptr = &variablename;` +--- How do you access the value stored at the memory address pointed by a pointer in C programming languages? @@ -32,8 +40,11 @@ ANS You maken use of the asterisk e.g +```c int * ptr = # printf("%d", *ptr); // this will print the value in num; +``` +--- What is a null pointer in C programming languages? @@ -41,6 +52,7 @@ ANS === Null pointers are pointers thst have been declared but not pointing to a particular memory location or address. They are initialized with the value NULL. +--- How do you declare pointers to pointers in C programming languages? @@ -49,7 +61,9 @@ ANS You declare pointer to pointers using double asterisks e.g -int **ptr; + +`int **ptr;` +--- What is the relationship between pointers and arrays in C programming languages? @@ -59,23 +73,19 @@ ANS The relationship between a pointer and an array is that both hold addresses to a location or memory space. A pointer holds the address of the variable it is pointing to while the arrayname serves as a pointer to the memory space it has been allocated to keep for a particular size of element of the same datatype. +--- + What is dynamic memory allocation in C programming languages and how is it achieved using pointers? ANS === Dynamic allocation of memory is allocating memory at the time of execution (run time). The functions calloc() and malloc() support allocating of dynamic memory. +--- How do you deallocate dynamically allocated memory in C programming languages? ANS === -We dynamically allocate memory using the following -malloc, calloc, and realloc functiins. - -to use malloc -variable = malloc(sizeof(datatype)); -You have to free up the memory using the free function -e.g -free(variable); +`free(variable);` From eaacff31ad863583135ae65c1dbc2e83dae8bf32 Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Sun, 5 Feb 2023 02:23:39 +0100 Subject: [PATCH 15/19] Updated - Dukeson --- TASKS/Task-21-Pointers-Quiz.md | 49 ++++++++++++++++------------------ 1 file changed, 23 insertions(+), 26 deletions(-) diff --git a/TASKS/Task-21-Pointers-Quiz.md b/TASKS/Task-21-Pointers-Quiz.md index 4215489..c76e755 100644 --- a/TASKS/Task-21-Pointers-Quiz.md +++ b/TASKS/Task-21-Pointers-Quiz.md @@ -1,22 +1,20 @@ -What is the purpose of pointers in C programming languages? +# What is the purpose of pointers in C programming languages? ANSWER -=== Pointers are useful resources. A pointer holds the address of a variable through which the variable being pointed to can be directly manipulated. Both pointer variable and the variable being pointed to must be of the same datatype. -What is the difference between a pointer and a regular variable in C programming languages? +# What is the difference between a pointer and a regular variable in C programming languages? -ANS -=== +ANSWER The major difference between a regular variable and a pointer variable is that a regular variable passes data by the value stored in it while the pointer passes data by referencing the address of the variable being pointed to. + --- -How do you declare a pointer in C programming languages? +# How do you declare a pointer in C programming languages? -ANS -=== +ANSWER To declare a pointer in C programming language, @@ -31,12 +29,12 @@ To avoid gibberish values it is good to initialize your pointer: but to make it point to a variable or memory location `int * ptr = &variablename;` + --- -How do you access the value stored at the memory address pointed by a pointer in C programming languages? +# How do you access the value stored at the memory address pointed by a pointer in C programming languages? -ANS -=== +ANSWER You maken use of the asterisk e.g @@ -44,48 +42,47 @@ e.g int * ptr = # printf("%d", *ptr); // this will print the value in num; ``` + --- -What is a null pointer in C programming languages? +# What is a null pointer in C programming languages? -ANS -=== +ANSWER Null pointers are pointers thst have been declared but not pointing to a particular memory location or address. They are initialized with the value NULL. + --- -How do you declare pointers to pointers in C programming languages? +# How do you declare pointers to pointers in C programming languages? -ANS -=== +ANSWER You declare pointer to pointers using double asterisks e.g `int **ptr;` + --- -What is the relationship between pointers and arrays in C programming languages? +# What is the relationship between pointers and arrays in C programming languages? -ANS -=== +ANSWER The relationship between a pointer and an array is that both hold addresses to a location or memory space. A pointer holds the address of the variable it is pointing to while the arrayname serves as a pointer to the memory space it has been allocated to keep for a particular size of element of the same datatype. --- -What is dynamic memory allocation in C programming languages and how is it achieved using pointers? +# What is dynamic memory allocation in C programming languages and how is it achieved using pointers? -ANS -=== +ANSWER Dynamic allocation of memory is allocating memory at the time of execution (run time). The functions calloc() and malloc() support allocating of dynamic memory. + --- -How do you deallocate dynamically allocated memory in C programming languages? +# How do you deallocate dynamically allocated memory in C programming languages? -ANS -=== +ANSWER `free(variable);` From 5b93a4fe617f3c22ebc148234a39015fbc7537f0 Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Sun, 5 Feb 2023 02:26:20 +0100 Subject: [PATCH 16/19] Updated - Dukeson --- TASKS/Task-21-Pointers-Quiz.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/TASKS/Task-21-Pointers-Quiz.md b/TASKS/Task-21-Pointers-Quiz.md index c76e755..0599a19 100644 --- a/TASKS/Task-21-Pointers-Quiz.md +++ b/TASKS/Task-21-Pointers-Quiz.md @@ -49,7 +49,7 @@ printf("%d", *ptr); // this will print the value in num; ANSWER -Null pointers are pointers thst have been declared but not pointing to a particular memory location or address. They are initialized with the value NULL. +Null pointers are pointers that have been declared but not pointing to a particular memory location or address. They are initialized with the value NULL. --- @@ -77,7 +77,7 @@ A pointer holds the address of the variable it is pointing to while the arraynam ANSWER -Dynamic allocation of memory is allocating memory at the time of execution (run time). The functions calloc() and malloc() support allocating of dynamic memory. +Dynamic allocation of memory is allocating memory at the time of execution (run time). The functions `calloc() and malloc()` support allocating of dynamic memory. --- From 38acb303016d009a0c3f83e9cf78a35fa6773ae6 Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Wed, 8 Feb 2023 15:26:21 +0100 Subject: [PATCH 17/19] Some solutions to some of the tasks that was given - Dukeson --- TASKS/Task-26.c | 61 ++++++++++++++++++++++- TASKS/Task-27.c | 56 ++++++++++++++++++++- TASKS/Task-28.c | 54 ++++++++++++++++++++- TASKS/a.exe | Bin 0 -> 49217 bytes TASKS/core | 0 TASKS/dukeson_solution/a.exe | Bin 0 -> 49209 bytes TASKS/dukeson_solution/task14.c | 52 ++++++++++++++++++++ TASKS/dukeson_solution/task15.c | 83 ++++++++++++++++++++++++++++++++ TASKS/dukeson_solution/task16.c | 32 ++++++++++++ TASKS/dukeson_solution/task17.c | 58 ++++++++++++++++++++++ TASKS/dukeson_solution/task18.c | 1 + 11 files changed, 394 insertions(+), 3 deletions(-) create mode 100644 TASKS/a.exe delete mode 100644 TASKS/core create mode 100644 TASKS/dukeson_solution/a.exe create mode 100644 TASKS/dukeson_solution/task14.c create mode 100644 TASKS/dukeson_solution/task15.c create mode 100644 TASKS/dukeson_solution/task16.c create mode 100644 TASKS/dukeson_solution/task17.c create mode 100644 TASKS/dukeson_solution/task18.c diff --git a/TASKS/Task-26.c b/TASKS/Task-26.c index a3188fe..ba476f3 100644 --- a/TASKS/Task-26.c +++ b/TASKS/Task-26.c @@ -1,4 +1,63 @@ /* Write a program that takes an array of scores, and then outputs the array in reverse order. -*/ \ No newline at end of file +*/ + +#include +#include +void reverse_arr(int *arr, int size) +{ + int itr = 0; + + printf("The array ["); + for (itr = 0; itr < size; itr++) + { + printf("%d", arr[itr]); + if (itr < (size - 1)) + printf(", "); + } + printf("] printed in reverse order is ["); + + for (itr = (size - 1); itr >= 0; itr--) + { + printf("%d", arr[itr]); + if (itr > 0) + printf(", "); + } + printf("]\n"); +} + +void accept_arr(void) +{ + int size = 0, itr; + static int arr[20]; + + printf("How many numbers?:\t"); + if (scanf("%d", &size) == 1) + { + if (size <= 1) + { + printf("Your array size cannot be lesser than 1."); + exit(1); + } + else if (size > 20) + { + printf("Your array size cannot be more than 20."); + exit(1); + } + for (itr = 0; itr < size; itr++) + { + printf("Enter a number:\t"); + scanf("%i", &arr[itr]); + } + + reverse_arr(arr, size); + } +} + +int main(void) +{ + accept_arr(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task-27.c b/TASKS/Task-27.c index 16e5d59..43327b1 100644 --- a/TASKS/Task-27.c +++ b/TASKS/Task-27.c @@ -1,4 +1,58 @@ /* Write a program that takes an array of scores and outputs the highest score and the lowest score -*/ \ No newline at end of file +*/ +#include +#include + +void sort_array(int *arr, int size) +{ + int low = 0, high = 0, itr = 0; + + low = arr[0]; + high = arr[0]; + for (itr = 1; itr < size; itr++) + { + if (arr[itr] < low) + low = arr[itr]; + if (arr[itr] > high) + high = arr[itr]; + } + + printf("\n\nHighest Score:\t%d\nLowest Score:\t%d", high, low); +} + +void arr_high_low_score(void) +{ + int size = 0, itr; + static int arr[20]; + + printf("Class Size?:\t"); + if (scanf("%d", &size) == 1) + { + if (size < 1) + { + printf("Your class size cannot be lesser than 1."); + exit(1); + } + else if (size > 20) + { + printf("Your class size cannot be more than 20."); + exit(1); + } + for (itr = 0; itr < size; itr++) + { + printf("Enter a score:\t"); + scanf("%i", &arr[itr]); + } + + sort_array(arr, size); + } +} + +int main(void) +{ + arr_high_low_score(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/Task-28.c b/TASKS/Task-28.c index ae109e3..a51b51f 100644 --- a/TASKS/Task-28.c +++ b/TASKS/Task-28.c @@ -3,4 +3,56 @@ Write a program to take input of how many students, calculate the average marks of the class by using an array to store the marks of each student and then using a loop to calculate the sum and average of all the marks. -*/ \ No newline at end of file +*/ +#include +#include +void sum_array_score(int *arr, int size) +{ + int itr = 0; + int total_score = 0; + + printf("\nThe sum of the scores in the array ["); + for (itr = 0; itr < size; itr++) + { + printf("%d", arr[itr]); + if (itr < (size - 1)) + printf(", "); + total_score += arr[itr]; + } + printf("] is = %d", total_score); +} + +void accept_arr(void) +{ + int size = 0, itr; + static int arr[20]; + + printf("How many numbers?:\t"); + if (scanf("%d", &size) == 1) + { + if (size <= 1) + { + printf("Your array size cannot be lesser than 1."); + exit(1); + } + else if (size > 20) + { + printf("Your array size cannot be more than 20."); + exit(1); + } + for (itr = 0; itr < size; itr++) + { + printf("Enter a number:\t"); + scanf("%i", &arr[itr]); + } + + sum_array_score(arr, size); + } +} + +int main(void) +{ + accept_arr(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/a.exe b/TASKS/a.exe new file mode 100644 index 0000000000000000000000000000000000000000..8d5ee95936e44653b0bab0993603d2463ea9174d GIT binary patch literal 49217 zcmeIb3w%`9c`v%=Av6qw9w1?XAs#!z7A^=0#LEVIMxzm$cqENABMcaOGnyGm6Gj?& z9w0DDafEEEgL0L7-5j@Z8>oGL^=+J%GUG{9f=dRy9LL#{-PLHUnG%)#eg| zIb1|2GYLexs!HG-+fEkRSsRb$qBvhqfI95ZnSF>Zw9Uin#%nVIF-L{z!A`W?*mWE5 zJS)kb*v>of6TpS}Ty zquAZpZ^N$JJgls7WkWrO1S~k5!cO$IbCCMO@z$*2*UKpVEOxTb4(z&(rCAzY*j zI3@g@9Hjn0kH(ej>-hDb@n0|}ye<`mpAbDGnGpG2p?tRi(mghGe)$mwQBO8im$9Av=qM9Mdj%cs)m1n=Nohwa zpvFj3wQHggq7R)|e!P2ZG+1pPdhh~o-N_KM?0VTayb|cogXZ$Aq$Os z_pQ$jzf(GV)XG@=NEOL&rZ8wPtO-8gVUrabPL>{AgCww;Ky9A-&d_=L$mt8EU)U7q z=FR`;NH0$6&kS9(lpg#LF!}ZHc>hfP(sKrRUJzrNeLG_elgUO5N#U zqYZySHFKn)dSXQdDL>*LD^yYmmVPn?QAUoBHorUa-4XvG%c&9nVdE!+-H+<}|{5K2!LpJ}|Nic)~{9{iN zpNWScz>(Agkf@S8Xr$~2KfvloC>@StKSH7st7lNqg}GFRo^;`7_?6Owe^0b3sVs+I z&pRjn4!n*~+Gyg!wtMfF?i-E13x6wp&i}?aJGs25#=OkG%54qr82;&hOiiK0DELj} zi2`{Jxy0};w)9$g6it4G#+`?OW9-}@P+*aBXMaC6MT(9CIQk{fW}{!HU-;U|A}UUv<&!YO z&9ekz#6+f-b~g+3>XC?9QKqo2v~$+?hH+aT}I`Klv?1PNz@ z5T|(R2#ExU3z|+ZZRdk7=}#2xjMT$KyM<9}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!mYbf`5# zPbveHv!XVv21DQ@u_^#=2H4g6ElRmx!-}neG%IUP0^u0%|Rif62Gm~dWRD-6I@X{!Th;k2K!K03JngX{{ zW%op*Ni@rd^^q*rpVyo)#M`|vh8Nx}IvsI3SjSrvf~x(_KvxrC}J5y+^aMQU%o3gNg!8V>X{wT1G!0SM8NhiSS0w6bcjr z@w>vZvEHp;HFXQ5P~yREI)4>)LbMk8UI?vYP16a<2)=ZvI>Nj6@Z>2dX_As!c%q_- z_U+E*c1!&fsr5ZEea#a$>Xp_`b4tCCC?m9lX5qQ3DAQW99rvh}P588_9hemT`}|nf zoI2u4A3-i<8uuIeKbm9ctKXEJ)vNbMY3Q9tP1%R`gU^3R(}y@ybA9y&R_PlVW-PE= vwmjyQ)h6wR<)77*qQ{Q}p7d?)~JHMsRXLOdsduo2vf{D9?{G literal 0 HcmV?d00001 diff --git a/TASKS/dukeson_solution/task14.c b/TASKS/dukeson_solution/task14.c new file mode 100644 index 0000000..b5de8d9 --- /dev/null +++ b/TASKS/dukeson_solution/task14.c @@ -0,0 +1,52 @@ +#include +#include + +/* Create a program to find the average of a set of numbers. */ + + +int sum_array(int argc, char *argv[]) +{ + int i = 1; + int sum = 0; + + for (i = 1; i <= argc; i++) + { + sum += atoi(argv[i]); + } + return (sum); +} + +double get_average(int argc, char *argv[]) +{ + int sum = 0; + int count = 0; + double avg = 0; + + sum = sum_array(argc, argv); + count = argc - 1; + avg = (double)sum / (double)count; + return (avg); +} + +int main(int argc, char *argv[]) +{ + int i = 1; + int count = 0; + + if (argc > 1) + { + count = argc - 1; + printf("The sum of the array ["); + for (i = 1; i < argc; i++) + { + printf("%d", atoi(argv[i])); + if (i < (argc - 1)) + printf(", "); + } + printf("] = %d", sum_array(argc, argv)); + printf(" and the average of the %d numbers is %.2f.\n", count, get_average(argc, argv)); + } + else + printf("Please enter some numeric data along side your program name."); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task15.c b/TASKS/dukeson_solution/task15.c new file mode 100644 index 0000000..8a98229 --- /dev/null +++ b/TASKS/dukeson_solution/task15.c @@ -0,0 +1,83 @@ +#include +#include + +/* Write a program that implements different mathematical functions such as +finding the factorial of a number, +calculating the power of a number, +and finding the square root of a number. */ + +int get_factorial(int a) +{ + if (a == 0) + return (1); + if (a == 1) + return (a); + return (a * get_factorial(a - 1)); +} + +double get_power(int num, int pow) +{ + int itr; + double pwr = 1.0; + + for (itr = pow; itr > 0; --itr) + pwr *= (double)num; + return (pwr); +} + +int get_square_root(int num) +{ + double sqrroot = 1; + int itr = 0; + while (1) + { + itr++; + sqrroot = (num / sqrroot + sqrroot) / 2; + if (itr == num + 1) + break; + } + return (sqrroot); +} + +int accept_value(void) +{ + int num = 0; + + printf("Enter a number:\t"); + if (scanf("%d", &num) == 1) + return (num); + return (0); +} + +int main(void) +{ + char *options = "Make a Choice:\n1 - [Factorial]\n2 - [Power]\n3 - [Square Root]\n"; + int first, response, second; + + printf("%s", options); + if (scanf("%d", &response) == 1) + { + switch (response) + { + case 1: + first = accept_value(); + printf("\nFactorial of %d! = %d\n", first, get_factorial(first)); + break; + case 2: + first = accept_value(); + second = accept_value(); + printf("\n%d raised to the power of %d = %.0f\n", first, second, get_power(first, second)); + break; + case 3: + first = accept_value(); + printf("\nThe square root of %d = %d\n", first, get_square_root(first)); + break; + default: + printf("\nChoose from the options.\n"); + break; + } + } + else + printf("\nNumeric data required.\n"); + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task16.c b/TASKS/dukeson_solution/task16.c new file mode 100644 index 0000000..0523f4b --- /dev/null +++ b/TASKS/dukeson_solution/task16.c @@ -0,0 +1,32 @@ +#include +#include + +#define BUFSIZE 1024 + +/* Write a program to reverse a string. */ + +void rev_string () +{ + char *str; + int count = 0; + + str = (char *)malloc(sizeof(char) * (BUFSIZE + 1)); + printf("Enter a string of text:\t"); + scanf("%[^\n]%*c", str); + + for (count = 0; str[count] != '\0'; count++) + {} + for (count -= 1; count >= 0; --count) + printf("%c", str[count]); + printf("\n"); + + free(str); +} + + +int main(void) +{ + rev_string(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task17.c b/TASKS/dukeson_solution/task17.c new file mode 100644 index 0000000..1101cc1 --- /dev/null +++ b/TASKS/dukeson_solution/task17.c @@ -0,0 +1,58 @@ +#include +#include + +/* Write a program to find the largest and smallest number in an array. */ + +void sort_array(int *arr, int size) +{ + int low = 0, high = 0, itr = 0; + + low = arr[0]; + high = arr[0]; + for (itr = 1; itr < size; itr++) + { + if (*(arr + itr) < low) + low = *(arr + itr); + if (*(arr + itr) > high) + high = *(arr + itr); + } + + printf("\n\nHighest Value:\t%d\nLowest Value:\t%d", high, low); +} + +void accept_arr(void) +{ + int size = 0, itr; + static int arr[20]; + + printf("How many numbers?:\t"); + if (scanf("%d", &size) == 1) + { + if (size <= 1) + { + printf("Your array size cannot be lesser than 1."); + exit(1); + } + else if (size > 20) + { + printf("Your array size cannot be more than 20."); + exit(1); + } + for (itr = 0; itr < size; itr++) + { + printf("Enter a number:\t"); + scanf("%i", &arr[itr]); + } + + sort_array(arr, size); + } +} + + + +int main(void) +{ + accept_arr(); + + return (0); +} \ No newline at end of file diff --git a/TASKS/dukeson_solution/task18.c b/TASKS/dukeson_solution/task18.c new file mode 100644 index 0000000..6724ae3 --- /dev/null +++ b/TASKS/dukeson_solution/task18.c @@ -0,0 +1 @@ +#include \ No newline at end of file From e0cee4f6c5133a62f741df2b26838dcdd295a372 Mon Sep 17 00:00:00 2001 From: Dukeson Ehigboria O Date: Wed, 8 Feb 2023 15:27:21 +0100 Subject: [PATCH 18/19] Some solutions to some of the tasks that was given - Dukeson --- TASKS/a.exe | Bin 49217 -> 0 bytes TASKS/dukeson_solution/a.exe | Bin 49209 -> 0 bytes 2 files changed, 0 insertions(+), 0 deletions(-) delete mode 100644 TASKS/a.exe delete mode 100644 TASKS/dukeson_solution/a.exe diff --git a/TASKS/a.exe b/TASKS/a.exe deleted file mode 100644 index 8d5ee95936e44653b0bab0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2K!K03JngX{{ zW%op*Ni@rd^^q*rpVyo)#M`|vh8Nx}IvsI3SjSrvf~x(_KvxrC}J5y+^aMQU%o3gNg!8V>X{wT1G!0SM8NhiSS0w6bcjr z@w>vZvEHp;HFXQ5P~yREI)4>)LbMk8UI?vYP16a<2)=ZvI>Nj6@Z>2dX_As!c%q_- z_U+E*c1!&fsr5ZEea#a$>Xp_`b4tCCC?m9lX5qQ3DAQW99rvh}P588_9hemT`}|nf zoI2u4A3-i<8uuIeKbm9ctKXEJ)vNbMY3Q9tP1%R`gU^3R(}y@ybA9y&R_PlVW-PE= vwmjyQ)h6wR<)77*qQ{Q}p7d?)~JHMsRXLOdsduo2vf{D9?{G From 22194d00ddc098a1d10b9cff68c6808d0a8185ba Mon Sep 17 00:00:00 2001 From: Sampul-CodeMine Date: Wed, 15 Feb 2023 14:11:46 +0100 Subject: [PATCH 19/19] Solution to tasks. --- TASKS/dukeson_solution/a.out | Bin 0 -> 4492 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100755 TASKS/dukeson_solution/a.out diff --git a/TASKS/dukeson_solution/a.out b/TASKS/dukeson_solution/a.out new file mode 100755 index 0000000000000000000000000000000000000000..fa6a37b37b34bc11ccbb921dabea70b823321408 GIT binary patch literal 4492 zcmbVPYiJzT6+XLK+Z$_buU(~aWHn4&E0w|CT}f*_oE9uQHdQQ#MD>pZQpU48v)YYU zv&+mVmceaJ(;tP}btof@p)GEkX8V0J zbLG+YLCFzk&-umvRYfR)~WbMTRw zmujzV5YdJMrkQ;!e;j%eAo*0lw}Hv@Gj6i!neF|jH$Ke&1^5y6Z{+t6EBkm8`6zw^ zm`pnvuKFw%NpT-+WaZDgr(MsQ&K4?mwpy`IS`PAr|64&@8M95NRx$A14^x~|c8=f`m1IL=GV6h!oN;T)C)SZg$mBcL?c1hSO;C(v;Y^U6j~6+bOYOdML3By%nvuBFD>?=FUuOwUX9rYKCo6 zd`aug43sv?VH-JX-l>|_H?Ui?XQm65<7%!|HykX7shz5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