Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8817471
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 14, 20262026-06-14T04:51:25+00:00 2026-06-14T04:51:25+00:00

so im newbie here , im trying to write a program for a theater

  • 0

so im newbie here , im trying to write a program for a theater ticketing system.
this is just me trying to find out how to use while , so i can stop the program from taking the next step if the input is wrong , here is the while code:( i got it some where and i changed some stuff)

Movie_is = "a"# i want to assign more than one string like "A","b","B" etc
movie_slection = True

while movie_slection:
Choose=raw_input("Choose your movie by typing the correct letter")
if Choose != Movie_is:
    print 'Wrong input'
    movie_slection = False 
elif Choose == Movie_is:
    print 'Your movie is :'

else:
print 'Wrong input.'


print 'Done'</i>

and this is the other code that i want to use the 1st code in it , if i type d it goes to the tickets selection :

print "a.Fight Club (1999)", "b.Freaks (1932)","c.Barton Fink (1992)"

Movie_is=raw_input("Choose your movie by typing the correct letter")
if Movie_is == "a" or Movie_is== "A":
 movie = "Fight Club (1999)"
elif Movie_is == "b" or Movie_is=="B":
 movie = "Freaks(1932)"
elif Movie_is == "c"  or Movie_is== "C":
 movie = "Barton Fink (1992)"
else:
 movie = "You have entered a wrong letter ,\n note:this application is case sensitive"
print " Selected Movie : ", movie

# the tickets selection
Tickets_is=raw_input(" Select Tickets: a.(Adult) b.(Children) c.(Senior) d.(Student)")
if Tickets_is=="a" or Tickets_is== "A"  :  
tickets="""
    ||       SCREEN         ||

     1 2 3 4 5 6 7 8 9 10


  """

elif Tickets_is == "b" or Tickets_is=="B":
 tickets= """
    ||       SCREEN         ||

     1 2 3 4 5 6 7 8 9 10


  """
elif Tickets_is == "c" or Tickets_is== "C":
 tickets= """
    ||       SCREEN         ||

     1 2 3 4 5 6 7 8 9 10


  """
elif Tickets_is == "d" or Tickets_is== "D":
 tickets= """
    ||       SCREEN         ||

     1 2 3 4 5 6 7 8 9 10


  """

else:
 tickets= "You have entered a wrong input , please type a valid seat number"
print "Seats: ",tickets </i>

Thanks in advance .

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-14T04:51:27+00:00Added an answer on June 14, 2026 at 4:51 am

    You will want to use a list instead of a string:

    movies = [ 'a', 'b', 'c' ]
    for movie in movies:
        print movie
    

    But you probably want a class to define a movie. That allows you to collect all information about a single movie in one place.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

Java newbie here, I am trying to find the output of the following chunk
I'm a newbie to sql and am trying to follow this example here: http://net.tutsplus.com/tutorials/php/a-better-login-system/
Newbie C++ programmer here. I'm trying to write a command line application that takes
I am a newbie with ruby and was trying out something small. So this
Newbie here with a frustrating, but probably simple question. I am trying to write
Hadoop/Hive newbie here. I am trying to use data stored in a custom text-based
awk newbie here.. I'm trying this: top -b -p 30259 | awk 'BEGIN {
MVC3 and Entity framework newbie here. I'm trying to write a controller that will
I'm a C newbie and I was just trying to write a console application
Newbie here, I am trying to use Bioperl module in the perl environment. My

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.