Linked Questions

275 votes
15 answers
949k views

I am getting an error when I try to run this simple script: input_variable = input("Enter your name: ") print("your name is" + input_variable) Let's say I type in "dude",...
chillpenguin's user avatar
  • 3,099
1 vote
3 answers
4k views

Today I was writing this program from random import randint def practice(): command = input("Welcome to math practice! Type mult tables to practice multiplication tables, or simp add for single ...
iamthebacon's user avatar
0 votes
1 answer
420 views

My code is simple. The problem is input command. I try to write python code that accept user string input from the keyboard and display it. But it Generate this error message always SyntaxError: ...
pythones programers's user avatar
0 votes
1 answer
114 views

Is it possible to split an input of two integers separated by a space such as '1 2' to be split into two separate variables? I have tried ratio = input() a,b = ratio.split(' ') but it returns an ...
T. Green's user avatar
  • 321
0 votes
1 answer
63 views

I'm trying to create a program, where the user types a word 5 times and then I plot the results. But I can't get past the first input statement. import matplotlib.pyplot as plt import time as t ...
MojoMike's user avatar
1 vote
0 answers
75 views

I'm not sure what the issue is with my code but I get the error "Unexpected EOF while parsing" when attempting to go through my try and except code. Here is the code that's causing problems: ` def ...
IcePJ's user avatar
  • 21
0 votes
1 answer
76 views

I have made this code in an attempt to create a simple 'Create a user' program which take the inputs and puts them into a csv file however I am finding that I keep getting the error unexpected EOF ...
J.Arthur's user avatar
12 votes
4 answers
36k views

I have this code: # Compare phone number phone_pattern = '^\d{3} ?\d{3}-\d{4}$' phoneNumber = str(input("Please enter a phone number: ")) if re.search(phone_pattern, "258 494-3929&...
coson's user avatar
  • 8,699
2 votes
4 answers
45k views

When testing my program, I keep getting this error: 1. Encrypt a file 2. Decrypt a file ----> 1 Enter the filename you'd like to encrypt: test Traceback (most recent call last): File "./encrypt....
CodyT96's user avatar
  • 175
4 votes
1 answer
2k views

I have code wrote on Windows, compiles and works correctly, but fails on the raspberry pi wrote some simple test code to see if it spits out the same error a = input('this is a test string to split ...
Luka's user avatar
  • 43
0 votes
1 answer
2k views

i had created a python program but it was not working. this program would take in the input for a file and then display the file contents . the only error i was getting is a syntax error well i could ...
Anurag-Sharma's user avatar
0 votes
1 answer
1k views

I'm writing a console application in python 3, and when I run my code in the Pycharm IDE, it runs just fine. If I run the code by opening it in python3, I get the exception "unexpected EOF while ...
icaughtfireonce's user avatar
0 votes
2 answers
826 views

I have a slight problem trying to run a python program from the terminal on my Mac. When my '.py' program has a 'input ("press the enter key to find out.")' command the terminal gives the following ...
joesh's user avatar
  • 181
-2 votes
1 answer
837 views

Note: This question is about a problem with repl.it, not a general problem. Note: You might consider this as a duplicate, but in fact it isn't. These do not suit my problem: ...
EKons's user avatar
  • 915
0 votes
2 answers
976 views

Here's the syntax of the problem I'm facing: Heating and cooling degree-days are measured by utility companies to estimate energy requirements. If the average temperature for a day is below 60, then ...
user3537776's user avatar

15 30 50 per page