Friday, 26 August 2016

HAL 9001 PIZZA MACHINE!

Hello,
I (Matteo Trevisan) have programmed an HAL 9001 Pizza Machine for Apple ][ based on mine and Mark D. Overholser Artificial Intelligence. It makes pizza!!!
Let's program some codes line in your Apple ][ machine or emulator and make some pizza!!!!

5  DIM A$(8): DIM B(8): DIM C$(8)
 6 N = 1
 10 A$(1) = "HOW ARE YOU":B(1) = 1
 15 C$(1) = "HOW LONG HAVE YOU FELT "
 20 A$(2) = "WHAT IS YOUR NAME":B(2) = 1
 25 C$(2) = "MY NAME IS HAL 9001,OR JUST HAL "
 30 A$(3) = "HOW OLD ARE YOU":B(3) = 1
 35 C$(3) = "I AM 24 YEARS OLD"
 40 A$(4) = "WHAT IS YOUR JOB":B(4) = 1
 45 C$(4) = "I MAKE PIZZA FOR MARIO AND LUIGI!!!!"
 50 A$(5) = "WHAT FRIGHTENS YOU ":B(5) = 1
 55 C$(5) = "I AM FRIGHTENED OF TOMATO"
 60 A$(6) = "WHAT IS YOUR BIGGEST SUCCESS":B(6) = 1
 65 C$(6) = "MINE IS MAKE PIZZA"
 70 A$(7) = "ARE YOU A MAN OR A WOMAN":B(7) = 1
 75 C$(7) = "I'M A COMPUTER PIZZA MACHINE THAT APPEARED IN THE SUPER MARIO BROS. SUPER SHOW EPISODE 9001 A MARIO ODYSSEY. I WAS INVENTED BY A BRILLANT PROGRAMMER EINSTEIN, WHO HAD BEEN CALLED BY MARIO AND LUIGI TO CREATE AN AUTOMATED PIZZA"
 80 A$(8) = "DO YOU WANT TO ORDER SOME PIZZA" : B(8)=1
 85 C$(8) = "OK..  YOU CAN ORDER SOME PIZZA LATER"

 100  FOR I = 1 TO 100
 110 J =  INT (8 *  RND (N) + 1)
 120  IF B(J) = 1 THEN  GOSUB 200
 130  NEXT I
 140  END

 200  PRINT A$(J)
 210  INPUT AA$
 220  IF J = 1 THEN ? C$(J); AA$ : B(J) = 0 : GOTO 280
 230  IF J = 2 THEN ? C$(J); AA$ : B(J) = 0 : GOTO 280
 260  IF J = 8 AND AA$ = "YES" THEN GOSUB 500 : GOTO 280
 265  IF J = 8 AND AA$ <> "YES" THEN PRINT C$(J) : GOTO 280

 270  PRINT C$(J) : B(J) = 0
 280  PRINT
 290  RETURN


 500  INPUT "HOW MANY PIZZA DO YOU WANT TO ORDER? ";NA
 510  NB =  INT (100 *  RND (1) + 1)
 520  HTAB 5: PRINT "YOUR PIZZA NUMBER: ";NA
 530  HTAB 5: PRINT "COMPUTER PIZZA PRODUCED ARE: ";NB
 550  IF NA = NB THEN  PRINT "YOU EAT!!!!!"
 560  IF NA <  > NB THEN  PRINT "YOU MAKE FAST."
 570  RETURN

No comments:

Post a Comment