Make a backup file: Difference between revisions
Content added Content deleted
Line 76: | Line 76: | ||
}</lang> |
}</lang> |
||
=={{header|Pike}}== |
|||
<lang Pike>string targetfile = "pycon-china"; |
|||
targetfile = System.resolvepath(targetfile); |
|||
mv(targetfile, targetfile+"~"); |
|||
Stdio.write_file(targetfile, "this task was solved at the pycon china 2011");</lang> |
|||
=={{header|Ruby}}== |
=={{header|Ruby}}== |
||
This version does not overwrite the backup file if it exists. |
This version does not overwrite the backup file if it exists. |