11.07.2015 Views

Here - 1000 BiT

Here - 1000 BiT

Here - 1000 BiT

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

SET TRAPS FOR ERRORSExample: Add this line to the above lines:386 IF R$O"N" THEN GOTO 380Line 380 asked for only two choices, Y or N. If the user presses some other key, line 386sends him back to line 380.Traps make your program "bomb proof " so that users will be unable to goof it up!Assignment 32:1. Make a program to write a very large number, 50 digits. Pick the digits at random. Puta comma between each set of three digits. Hint: Make the digits one at a time fromRND(O) and glue them on the end of the number.2. Write a secret cipher program. The user chooses a password and it is used to make acipher alphabet like this:If the password is DRAGONETTEremove the repeated letters, get DRAGONETput it at the front of the alphabet and the rest ofthe letters after it in normal orderDRAGONETBCFHIJKLMPQSUVWXYZcipher alphabetABCDEFGHIJKLMNOPQRSTUVWXYZnormal alphabetThe user chooses to code or decode from a menu.189

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!