# CSE102-Computer Programming Homework #6 solved

\$35.00

Category:

## Description

1) Write a code which should perform the following operations. It has to take two numbers from
user and find multipliers of numbers with a common() function .
For example; Factors of 24 {2,2,2,3}
Factors of 32 {2,2,2,2,2}
Then calculate the common factors recursively which are {2,2,2} and function has to return 2*2*2.
2) Write a code which should perform the following operations. User should enter the length of list
and list elements like the list. You can take the list of numbers in the main function.
For example;
Enter the length of the list: 10
Enter the elements of list:
3
9
23
1
8
22
67
0
16
52
Then you should create a function that takes the numbers and show the new list with increasing
order. Function has to divide the list into two lists recursively until it can no more be divided. After
that it combines all elements with increasing order. Output of the program should be like:
Sorted array is :0 1 3 8 9 16 22 23 52 67.
3) Write a code which should perform the following operations. User should enter an input
number. Then create a function which will calculate the output numbers recursively using
following formula.
For example; Input: 45
Output: 45 136 68 34 17 52 26 13 40 20 10 5 16 8 4 2 1
4) Write a code which should perform the following operations. User should enter a number and
the code has to check if the number fits the formula or not . Create a function which is checking the
input number recursively. Function should gives results “equal” or “Not Equal”.
Spring 2019 CSE102-Computer Programming Homework #6
F(x)= (
𝒆𝒒𝒖𝒂𝒍, 𝒁𝑿𝑪𝑽 = 𝒁
𝑵 + 𝑿
𝑵 + 𝑪
𝑵 + 𝑽
𝑵
𝒏𝒐𝒕 𝒆𝒒𝒖𝒂𝒍, 𝒁𝑿𝑪𝑽 ≠ 𝒁
𝑵 + 𝑿
𝑵 + 𝑪
𝑵 + 𝑽
𝑵
) N=number of digit
example: Input=371
Output: Equal
Input=372
Output: Not Equal
5) Write a code which should perform the following operations. User should enter a string without
space and code should find the first capital letter in the string. You have to write a function which
finds the letter recursively.
Input: computerScienceAndEnginnering
Output:S
General Rules:
1. Obey and don’t broke the function prototypes that are shown on each
part, if any, otherwise, you will get zero from the related part.
2. You can use the functions that I wrote.
3. Note that if any part of your program is not working as expected, then
you can get zero from the related part, even it’s working in some way.