At the beginning was very difficult to me because I didn’t know how to do anything, but with some research and help, now I understand and I know how to do it. Here are my codes: Question 1: https://github.com/Andreandc/TC1017/blob/master/q1fibonacci.cpp Question 2: https://github.com/Andreandc/TC1017/blob/master/q2palindrome.cpp
In this pages you can see the programs for quiz 7
https://github.com/dianagdv/TC101/blob/master/Quiz7_1
https://github.com/dianagdv/TC101/blob/master/Quiz7_2
At the moment I was doing the quiz I was so confused because I didn’t know how that works. After some research I just found out how to do both problems. Github code: https://github.com/luisduartepalacios/Quiz07
Write a function called fibonacci which receives a lon “n” and returns a long which is the value of the nth number in the fibonacci series which is: 0,1,1,2,3,5,8,13,21,34,55,89………. So, fibonacci(0) woud return 0, fibonacci(5) would return 5, fibonacci(8) would return 21. Note that the first two fibonacci numbers are 0 and 1. All others … Continue reading #Quiz07 →
So… Here’s my code for the quiz. It was quite interesting quiz to make. It wasn’t that the task was hard but at least for the second one I had to think on it a tad bit more. https://github.com/Dragv/quiz7/tree/master
This one was a little bit difficult, but by reading the book I understand it. q1.cpp #include <iostream> using namespace std; long fibonacci(long x){ long y=0; long z=1; long t=0; while (x>1){ t=y+z; y=z; z=t; x=x-1;} return t; } int main (){ long x; cout << “Escribe el numero que deceas calcular= “; cin >> […]
Q1: https://github.com/A01154027/TC101/blob/master/Quiz%2007%20q.1 Q2: https://github.com/A01154027/TC101/blob/master/Quiz%2007%20q2.cpp cheers!
Photo credit: https://flic.kr/p/4r69rq Hola amigos, tuve algunos problemas con mi código pero lo corregí y todo salió bien. Aqui están mis códigos: https://github.com/BrayanGc/Codigos/blob/master/Q7q1.cpp https://github.com/BrayanGc/Codigos/blob/master/Q7q2.cpp
This one was a little bit difficult, but by reading the book I understand it. q1.cpp #include <iostream> using namespace std; long fibonacci(long x){ long y=0; long z=1; long t=0; while (x>1){ t=y+z; y=z; z=t; x=x-1;} return t; } int main (){ long x; cout << “Escribe el numero que deceas calcular= “; cin >> […]
Q1: https://github.com/A01154027/TC101/blob/master/Quiz%2007%20q.1 Q2: https://github.com/A01154027/TC101/blob/master/Quiz%2007%20q2.cpp cheers!