Skip to content

UMK-Data-Science/recursive-algo-tutorial

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Tutorial 5 - Recursive and Algorithm Efficiency

Please answer all questions and read carefully :octocat:

Instructions

This tutorial consists with 6 questions. Try to complete this tutorial by commit your changes and read the question carefully 😄

Exercise 1

Write C program to calculate the sum of numbers from 1 to 10 using recursion

Expected Output: 
The sum of numbers from 1 to 10 is 55

Exercise 2

Write C program to print Fibonacci Series using recursion where the input number of series is N = 10

Expected Output: 
The Series are: 1 1 2 3 5 8 13 21 34 55

Exercise 3

Write C program to find the Factorial of a number using recursion where the test data, N = 5

Expected Output: 
The Factorial of 5 is 120

Exercise 4

Write C program to count the digits of a given number using recursion

Test Data
Input a number: 50
Expected Output:
The number of digits in the number is 2

Exercise 5

Write a C program to find the sum of digits of a number using recursion function

Test Data
Input any number to find sum of digits: 25
Expected Output: 
The sum of digits of 25 is 7

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages