1. Welcome to PHCorner Forums. Take a moment to Sign up and gain unlimited access and extra privileges that guests are not entitled to, such as:

    All that and more! Registration is quick, simple and absolutely free. Join our community today!

Tutorial code for making a simple quiz game using notepad and cmd

Discussion in 'Coding, Programming' started by connectibyte, May 29, 2015.

  1. steps:
    1,)open notepad
    2.)type this code;
    echoecho off
    :menu
    cls
    echo Hello, Welcome to salazar's Game
    echo What would you like to do ? ? ?
    echo 1) Start Game
    echo 2) Exit Game
    set /p letter=

    if %letter% == 1 goto start game
    if %letter% == 2 goto to exit game
    goto menu
    :start game
    cls
    echo Level 1
    echo Hello, Enter your name:
    set /p name=
    echo hello, %name%!
    echo how are you:
    set /p lala=
    echo You are feeling %lala%!
    echo That's Nice
    pause
    echo In which class you are studying:
    set /p class=
    echo You are studying in %class%
    echo That's Nice
    echo Means you are the children of Senior Wing !
    echo That's
    pause
    echo Anyway
    echo In which school you study:
    set /p school=
    echo You study in %school%!
    echo That's Nice
    echo The one who made me even study in %school%!

    echo What is your ClassTeacher name:
    set /p classteacher=
    echo Oh ! Your ClassTeacher name is %ClassTeacher%!
    echo Means the one who made me and you are friends!!!
    pause
    echo Am I Right: (yes or no)

    set /p right=
    if %letter% == yes WoW !
    if %letter% == no Never Mind

    echo Aman never told me about it !
    echo Who teaches you Social Science:
    set /p social science=
    echo %social science% Mam teaches you Social Science !!

    echo Itz Goooood !@!
    echo What's your Principal Mam name:
    set /p principal=
    echo Your principal name is %principal% !

    echo What is your mother's name:
    set /p name=
    echo Your Mother's name is %name% !
    echo Nice Name

    echo Ok Then Bye for NOW !!!!!!!!!
    echo Nice talking with you !
    pause
    3.)save it as mygame.bat and=====choose all files
    RUN IT!!!!AND YOUR DONE :)
     
  2. palitan ng @ ang ? sa umpisa ng code ang ? echo off
     
    AIZEN_10 likes this.
Tags / Keywords: