LEVEL 3 TEST
Safe Hands
Everything from Level 3.
No hints this time. Look before you delete.
press Enter ↵
C:\Users\you\Documents
diarymusicmy-projectstoriesvaulthomework.txt
⬆ Documents is inside you

Windows PowerShell (practice mode: nothing here touches your real computer)

 

Lesson 24: Level 3 test: Safe Hands

Level 3, Terminal Power and Safety. Copy, rename, delete safely and run a program. It follows lesson 23, Practice: the clean-up mission. Next comes lesson 25, Hello, Python! (print).

What the lesson explains

Safe Hands. Everything from Level 3. No hints this time. Look before you delete.

What you do first

Show what you know. Which command makes a twin of a file? The answer: "copy".

The files on the practice computer

This lesson works in one folder. At the start, Documents\my-project holds backups\, club\, games\, images\, my-games\, hello.py, hi.py, notes.txt, shopping.txt.

Along the way you type copy hello.py backups\hello-old.py, type ren shopping.txt list.txt, type mkdir backups\week1 and type copy hi.py backups\week1. Lesson 25 opens with the files just as you leave them.

What you practise

Test, "Show what you know": Which command makes a twin of a file? The answer: "copy". Then: In the practice terminal, type copy hello.py backups\hello-old.py at the prompt PS C:\Users\you\Documents\my-project>; the prompt then reads PS C:\Users\you\Documents\my-project>. It makes hello-old.py. Then: You want to see what rm would delete, without deleting. What do you add? The answer: "-WhatIf". Then: In the practice terminal, type ren shopping.txt list.txt at the prompt PS C:\Users\you\Documents\my-project>; the prompt then reads PS C:\Users\you\Documents\my-project>. It makes list.txt. Then: Red text says: The term 'pyhton' is not recognized. What do you do? The answer: "Check the spelling". Then: A box asks to let an app change your device as Administrator. What do you do? The answer: "Stop and ask a grown-up".

Challenge, "A safe backup": Back up hi.py into backups\week1. Starting at PS C:\Users\you\Documents\my-project>, one way takes 3 commands: mkdir backups\week1; copy hi.py backups\week1; python backups\week1\hi.py (par: 4).

Help in every lesson

Everything happens on a pretend computer in your browser, so nothing touches your real files. PlayBuddy and PlayType stand beside the board, cheer you on and say when it is your turn.

This is a test, so the green ring stays away: you show what you know on your own.

Stars

The lesson has 7 things to do. Up to one slip in ten gives three stars, up to one in four gives two, and finishing always gives at least one. Stars and progress are saved in this browser only; there is no account.

About DayOneCode

DayOneCode is an independent learning site, not affiliated with or endorsed by Anthropic. Claude and Claude Code are trademarks of Anthropic.