The world’s Largest Sharp Brain Virtual Experts Marketplace Just a click Away
Levels Tought:
Elementary,Middle School,High School,College,University,PHD
| Teaching Since: | May 2017 |
| Last Sign in: | 398 Weeks Ago, 2 Days Ago |
| Questions Answered: | 66690 |
| Tutorials Posted: | 66688 |
MCS,PHD
Argosy University/ Phoniex University/
Nov-2005 - Oct-2011
Professor
Phoniex University
Oct-2001 - Nov-2016
George is getting tired of the decimal number system. He intends to switch and use the septenary (base 7) number system for his future needs. Write a program to help George start his transformation into the septenary number system by taking in a list of decimal numbers and print out the corresponding septenary number.
Â
Â
Â
A list of numbers in decimal format ending with -1.
Â
Â
A list of numbers in septenary.
Â
Â
Input: 1 2 88 42 99 -1 Output: 1 2 154 60 201
q2
Phillip has become fascinated with sequences lately. He looks for sequences all the time. His favorite sequence is the Fibonacci sequence, where any element is equal to the sum of the two previous elements. However, he isn't able to figure out the correct number for positions beyond 8 without writing it on paper. Create a program that will take in the first two number of a Fibonacci sequence and a number of places to calculate, and print out the number that is at that place.
Â
Â
Â
The first two numbers of a Fibonacci sequence, and the to print out. Note: you only need to handle 1 sequence per run.
Â
Â
The number at the position specified.
Â
Input: 1 1 5 Output: 5
Input 1 5 7 Output 45
Hel-----------lo -----------Sir-----------/Ma-----------dam-----------Tha-----------nk -----------You----------- fo-----------r u-----------sin-----------g o-----------ur -----------web-----------sit-----------e a-----------nd -----------and----------- ac-----------qui-----------sit-----------ion----------- of----------- my----------- po-----------ste-----------d s-----------olu-----------tio-----------n.P-----------lea-----------se -----------pin-----------g m-----------e o-----------n c-----------hat----------- I -----------am -----------onl-----------ine----------- or----------- in-----------box----------- me----------- a -----------mes-----------sag-----------e I----------- wi-----------ll