Code for a random heads or tails generator.
- Open notepad
- Copy code below
- Save it as ht.bat and click TEXT DOCUMENT and change it to ALL FILES
- Click save
echo To flip the coin press enter
set /p enter=
set /a a=%random% %% 2+1
if %a% EQU 1 (
echo Heads pause goto top
)else echo Tails pause goto top
Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.