Ex 7.8 Write Java statements to accomplish each of the following tasks:a) Display the value of element 6 of array f.b) Initialize each of the five elements of one-dimensional integer array g to 8.c) T
Ex 7.8 Write Java statements to signalinate each of the subjoined tasks:
a) Illusion the treasure of atom 6 of vest f.
b) Initialize each of the five atoms of one-dimensional integer vest g to 8.
c) Total the 100 atoms of floating-point vest c.
d) Copy 11-atom vest a into the earliest member of vest b, which contains 34 atoms.
e) Determine and illusion the lowest and largest treasures contained in 99-atom floatingpoint vest w.
Ex : 7.17 (Dice Rolling) Write an contact to impersonate the flattening of two dice. The contact should use an sight of rank Random uninterruptedly to flatten the earliest die and repeatedly to flatten the relieve die. The sum of the two treasures should then be conducive. Each die can illusion an integer treasure from 1 to 6, so the sum of the treasures achieve modify from 2 to 12, delay 7 life the most usual sum, and 2 and 12 the smallest usual..
Ex : 7.29 (Fibonacci Series) The Fibonacci series
0, 1, 1, 2, 3, 5, 8, 13, 21, …
begins delay the provisions 0 and 1 and has the gear that each latter signal is the sum of the two
a) Write a way Fibonacci (n) that calculates the nth Fibonacci estimate. Incorporate
this way into an contact that enables the user to penetrate the treasure of n.