我一直收到错误:FileNotFoundError:[Errno 2]没有这样的文件或目录:下面是我代码:
def main():
outfile = open('Bayofagbenro.txt')
Bayofagbenro =outfile.write ('Modupeola\n')
Bayofagbenro =outfile.w ('Ayobami\n')
Bayofagbenro =outfile.w ('AKintola\n')
Bayofagbenro =outfile.w ('Omonike\n')
Bayofagbenro =outfile.w ('Fehintoluwa\n')
Bayofagbenro =outfile.w ('Modupeola is 44yrs, Ayobami is 42 years, AKintola is 38 years, omonike is 36 years while fehintoluwa is 30 years')
outfile = Bayofagbenro.r
outfile.close
if __name__ == "__main__":
main()
期待着这样的东西:
print
1条答案
按热度按时间zzwlnbp81#
请尝试以下操作: