Examine the given Python program and select the purpose of the program from…

PYQ KVS TGT/PGT 2023

Examine the given Python program and select the purpose of the program from the following options: F=open('story.txt', 'r+') S=F.read() S=S.upper() F.seek(0) F.write(s) F.close()

  1. A.

    to count the upper case alphabets present in the file

  2. B.

    to convert all alphabets into uppercase in the file /

  3. C.

    to copy only the upper case alphabets from the file

  4. D.

    to remove all lower case alphabets from the file

Attempted by 1864 students.

Sign up free to check your answer

Sign up free

Explore the full course: Kvs Nvs Tier 2 Computer Science

Loading lesson…