import os,sys
sr=os.open("srinivas.txt",os.O_RDWR|os.O_CREAT)
line="this is test"
b=str.encode(line)
os.write(sr,b)
os.close(sr)
print("closed the function successfully")
sr=os.open("srinivas.txt",os.O_RDWR|os.O_CREAT)
line="this is test"
b=str.encode(line)
os.write(sr,b)
os.close(sr)
print("closed the function successfully")