K Output Cropped
K Output Cropped
K Output Cropped
NO: 6
DATE:
AIM:
To write a Python Program to Read a text file "Story.txt" line by line and display
each word separated by '#'.
SOURCE CODE:
Result:
Thus, the above Python program is executed successfully and the output is verified.
SAMPLE OUTPUT:
Story.txt:
***************************************************************************************
EX.NO: 7
DATE:
SOURCE CODE:
Result:
Thus, the above Python program is executed successfully and the output is verified.
SAMPLE OUTPUT:
Story.txt:
***************************************************************************************
EX.NO:8
DATE:
AIM:
To write a python program to read lines from a text file "Sample.txt" and copy those lines
into another file which are starting with an alphabet 'a' or 'A'.
SOURCE CODE:
Result:
Thus the above Python program is executed successfully and the output is verified.
SAMPLE OUTPUT:
New.txt:
*****************************************************************************************
EX.NO: 9
DATE:
AIM:
To write a Python Program to Create a binary file with roll number and name.
Search for a given roll number and display the name, if not found display
appropriate message.
SOURCE CODE:
Result:
Thus , the above Python program is executed successfully and the output is verified.
SAMPLE OUPUT:
*******************************************************************************************
EX.NO: 10
DATE:
SOURCE CODE:
Result:
SAMPLE OUTPUT:
**********************************************************************************
EX.NO: 11
DATE:
AIM:
To write a Python program Create a CSV file to store Empno, Name, Salary and
search any Empno and display Name, Salary and if not found display appropriate
message.
SOURCE CODE:
Result:
Thus, the above Python program is executed successfully and the output is verified.
SAMPLE OUTPUT:
PYTHON PROGRAM EXECUTED OUTPUT:
******************************************************************************
EX.NO: 12
DATE:
Result:
SAMPLE OUTPUT:
Python Program Executed Output:
****************************************************************************************