Write a code segment that will read in a sequence of numbers…
Write a code segment that will read in a sequence of numbers, as many numbers as the user wishes to enter, and then prints to the screen one number that is the total of all the numbers entered. Be sure to create any variables needed in the code segment.Write a code segment that will read in a sequence of numbers, as many numbers as the user wishes to enter, and then prints to the screen one number that is the total of all the numbers entered. Be sure to create any variables needed in the code segment.