Int(raw_input()) only seems to work online?

It’s not a specific question, but if I try and run scripts in actual python, the raw_input function can’t be understood and always means that the code doesn’t work. Is there any way to avoid this?

Use Python2.7 for compatibility with codecademy or adapt it to Python3