Math, asked by Shantanu4240, 1 year ago

Alice was bored that day,so she was sitting on the riverbank .suddenly she notices a talking, wte rabbit with a pocket watch .it ran fast,and she followed it, down a rabbit hole .she fell into the hole and found a magical wonderland with dark trees, beautiful flowers.she found many ways numbered from 1,2,3,........18.she was confused wch is the right way that will lead her to her home. she found a cute bird, standing in one of the tree. alice asked the bird the way to go back to her home.the bird said a two digit number( say 23 ) and asked her to find the sum of its digits (2+3=5) and that numbered way will lead her to her home.alice was already confused, so pls help alice in finding the route to her home.... input format: input consists of an integer corresponding to the 2-digit number.

Answers

Answered by ExoticExplorer
3
Input Format:
Input consists of an integer corresponding to the 2-digit number. 

Output Format:

Output consists of an integer corresponding to the sum of its digits. Refer sample input and output for formatting specifications. 
[All text in bold corresponds to input and the rest corresponds to output]

 SAMPLE INPUT OUTPUT 1 :
 The bird said:
 23
 Alice must go in path-5 to find her way to home

 SAMPLE INPUT OUTPUT 2 :
 The bird said:
 99
 Alice must go in path-18 to find her way to home 

Code:
#include<stdio.h> int main(){ int b,a,c; printf("The bird said:\n"); scanf("%d",&b); a=b%10; c=b/10; printf("Alice must go in path-%d to find her way to home",a+c); return 0; }

Hope This Helps :)
Similar questions