WRITE A PROGRAM IN C THAT DOES THE FOLLOWING:
The numbers are real numbers, read in as double precision floating-point numbers, one number perline, possibly with some white space before or after. Hint: use scanf. There are guaranteed to be no more than one million (that’s 10^6) numbers in the input, and no fewer than two legitimate numbers. Any number that is equal to zero should be ignored (discarded, not stored in the array or counted in any way).
#include <stdio.h>
int main()
{
//array declaration
double arr[1000000], temp;
//display message
//enter 10 times 9 for exit
printf("Enter an array of real numbers (enter 9999999999 for exit):
\n");
//input array element
for(long i = 0; i < 1000000; i++)
{
//input element
scanf("%lf",&temp);
//check if exit code
if(i > 1 && temp == 9999999999)
{
//break statement
break;
}
//ignore the zero
if(temp != 0)
{
arr[i] = temp;
}
else
{
i--;
}
}
return 0;
}
INPUT:

WRITE A PROGRAM IN C THAT DOES THE FOLLOWING: The numbers are real numbers, read in...
In C code prompt and read from the user an integer number, 'N', of double precision floating point numbers to allocate for the purpose of the current test run. Dynamically allocate an array of N double precision floating point numbers; i.e. the array will require "N*sizeof(double)" bytes of RAM for storage, call this M.
Arrays and reading from a file USE C++ to write a program that will read a file containing floating point numbers, store the numbers into an array, count how many numbers were in the file, then output the numbers in reverse order. The program should only use one array and that array should not be changed after the numbers have been read. You should assume that the file does not contain more than 100 floating point numbers. The file name...
Write a C++ program to find the kth largest number among N numbers. You may assume 0 < k <= N. The numbers are in an input file. Input value of k from the user. Read the first k numbers into an array and sort them into non-increasing order. Next, read the remaining numbers one by one (until end-of-file). As a new number is read, if it is smaller than the number in position k-1 in the array, it is...
Write a C program to read a counter, and then, read real
numbers based on the value of counter (the number must range from
0.0 to 100.0). Keep all the number entered into an array, and find
the biggest, smallest and the middle number. Use void
find_biggest_smallest() function to receive the array, and return
biggest and smallest number. Let say biggest and smallest is 14 and
2. Therefore average = (14+2)/2 = 8.
The middle number is the number which...
Need help figuring this out Write a program that reads in a sequence of numbers (doubles) from standard input until 0 is read, and stores them in an array, This part is done using iteration (loop). You may assume that the maximum size of the array will not be more than 100. Your program computes the maximum number stored in the array, the count of negative numbers, and computes the sum of positive numbers, using recursion. You need to have...
write a program that will read a file containing floating point numbers, store the numbers into an array, count how many numbers were in the file, then output the numbers in reverse order. Your program should only use one array and that array should not be changed after the numbers have been read. You should assume that the file does not contain more than 100 floating point numbers. Numbers found in file 100.7362 105.2896 66.3493 105.6688 91.6180 64.8770 73.9249 87.3441...
Write a C PROGRAM that will read in 10 floating-point numbers from the keyboard and load them into an array. Add up all the values and store the answer in a variable. Find the largest and smallest number in the array. Put each into its own variable. Print to the screen the sum, largest value, and smallest value. Copy the array to a second array in reverse order. Print out the second array. Read in 20 integer numbers, all in...
WRITE A PROGRAM IN C THAT DOES THE FOLLOWING Read a floating point number without using scanf or conversion functions from the C library. You would need to write a utility function that processes console input using only getc and/or getchar and flow of control logic to process character-based input from the console to process the input.
IN C language Write a C program that prompts the user to enter a line of text on the keyboard then echoes the entire line. The program should continue echoing each line until the user responds to the prompt by not entering any text and hitting the return key. Your program should have two functions, writeStr andcreadLn, in addition to the main function. The text string itself should be stored in a char array in main. Both functions should operate...
C- PROGRAMMING PROJECT #4 Design and Write a C program to calculate an average of an array of numbers and produce the following output: 1. Your first and last name 2. Course Number 3. C Project Number 4. All the numbers in the array 5. The sum of all the numbers in the array 6. The count of all the numbers in the array 7. The average of all the numbers in the array Double-space after lines 3, 4, 5,...