Question: Do correctly in java 1)Sum of N Fibonacci numbers Fibonacci numbers are a sequence of whole numbers arranged as 0, 1, 1, 2, 3, 5,

Do correctly in java

1)Sum of N Fibonacci numbers

Fibonacci numbers are a sequence of whole numbers arranged as 0, 1, 1, 2, 3, 5, 8, 13, 21, 34,... Every number is the sum of the preceding two numbers. Here are some interesting facts about the Fibonacci numbers:

This sequence is called the Fibonacci sequence and it's an infinite sequence.

Each number in the Fibonacci series or sequence is represented as Fn.

As shown below, Fibonacci numbers can be represented as a spiral, if we make squares with those widths. In the given figure, we can see how the squares fit neatly together. For instance, 5 and 8 add up to 13, 8 and 13 add up to 21, and it goes on.

Sample input: 10

Sample output: 88

2)

Find the area of geometric shapes

Find the area of the following geometric shapes:

Circle

Square

Rectangle

While finding the area all the pillars of Object Orientation such as Encapsulation, Polymorphism, Inheritance, and Abstraction are to be followed.

abstract class Shape{ // your code goes here } class Circle extends Shape{ // your code goes here } class Square extends Shape{ // your code goes here } class Rectangle extends Shape{ // your code goes here } class Geometry{ // your code goes here }

Output Window :

Enter radius: 25

Area: 1966.875

Enter the side: 25

Area: 625.0

Enter the length: 25

Enter the breadth : 25

Area: 625.0

3)Find the total number of vowels and consonants using loops

Convert the string to upper case so that comparisons can be reduced. Else we need to compare with capital (A, E, I, O, U).

If any character in the string matches with vowels (A, E, I, O, U, a, e, i, o, u ) then increment the vowel_count by 1.

If any other character, then increment the count for consonat_count by 1.

Print both counts.

Sample input: Hi Good MornIng to Everyone

Sample output: 9

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!