Description: |
Write a program to swap or exchange two numbers. You should not use any temporary or third variable to swap. |
Code: | ||
|
Output: |
Before swap: x value: 10 y value: 20 After swap: x value: 20 y value: 10 |
Description: |
Write a program to swap or exchange two numbers. You should not use any temporary or third variable to swap. |
Code: | ||
?
|
Output: |
Before swap: x value: 10 y value: 20 After swap: x value: 20 y value: 10 |
Description: |
In mathematics, the Fibonacci numbers or Fibonacci series or Fibonacci sequence are the numbers in the following integer sequence: 0, 1, 1, 2, 3, 5, 8, 13, 21, 34, 55, 89, 144... By definition, the first two numbers in the Fibonacci sequence are 0 and 1, and each subsequent number is the sum of the previous two. Below example shows how to create fibonacci series.
|
Code: | ||
?
|
Output: |
0 1 1 2 3 5 8 13 21 34 55 89 144 233 377 |