logo

Crowdly

The file /home/sharing/numbers.txt contains ten integers across seven lines....

✅ Перевірена відповідь на це питання доступна нижче. Наші рішення, перевірені спільнотою, допомагають краще зрозуміти матеріал.

The

file

/home/sharing/numbers.txt

contains

ten integers across seven lines. The task is to find out the average of these

ten integers and copy the integers as well as the average into another file

called

result.txt.

Additional

exercises:

  • Pick only those odd numbers from the ten

    numbers of the file and write these odd numbers, as well as their average into an

    output file.

  • Next, modify the original program so that

    instead of assuming the number of integers to be read from the file, the

    program reads till all the integers of the file are read.

Більше питань подібних до цього

Хочете миттєвий доступ до всіх перевірених відповідей на dle.plaksha.edu.in?

Отримайте необмежений доступ до відповідей на екзаменаційні питання - встановіть розширення Crowdly зараз!