I have two programs that i have to write by next friday (april 1 ) but i have no idea how to do them. Can someone please help me out. These are the **conditions for the 1st one:**

1) read floating point numbers into an array until teh sum of those numbers exceeeds 100.At teh element where the sum becomes greater than 100, store a -1.0 to denote that end of the array. Now print the number of elements in the aarray, not including the -1.0.

**Second one:**

2) initialize an integer array with six elements. find the largest element and swap it with the number in the first element. FOr example, if the array is 40, 80,20,50,90,30, after the swap the array should become 90,80,20,50,40,30.