Is Python used for C++?

Started by
14 comments, last by MENTAL 17 years, 6 months ago
Is the program Python used for C++, if it's not, I wouldn't know, I'm a newb.
Advertisement
uh depends on how you mean that.

python is a scripting language.
C++ is a computer language.

but some people do embed a python interpreter into c++
slymrHopefully game is in progress.
yeah, there are some games that use python as a scripting language for the game. So it is 100% possible to use python and C++ together. I used to know an example of a game that did this but I forgot.


Is that what you meant?

Chad.
Quote:Original post by slymr
python is a scripting language.
C++ is a computer language.


?

Last time I checked, python ran on computers too :)
Quote: Quote:
Original post by slymr
python is a scripting language.
C++ is a computer language.



?

Last time I checked, python ran on computers too :)


i think he meant that c++ is a systems programming language :->
I believe he meant
Python is a scripting language.
C++ is a programming language.


Although, you can make programs using nothing but Python.

However, in most applications of python I've seen that are non-web related it's usually as a sub-language running under a C++ program.

Web related I usually see it by itself used to build a Content Management System.

I haven't messed around with Python in a while though so things may be different now...

( I also forgot to mention that there's an entire game engine written entirely in Python. I forget its name though)
Pygame
Quote:Original post by Ceoddyn
Pygame


pygame isn't written entierly in python,
its written mainly in C and is a python module. (its using SDL aswell).

python can use native modules (generally written in C or C++)
native applications can use python (Civilazations 4 is one example)
[size="1"]I don't suffer from insanity, I'm enjoying every minute of it.
The voices in my head may not be real, but they have some good ideas!
Uh, I'm having a lot of difficulty guessing what you mean by "used for C++". C++ is a tool used for accomplishing things, not a thing to be accomplished. Unless perhaps you meant "used to generate C++ source code"? It can be, but you have to know both languages already to make it work at all, and be pretty good with C++ to make it *useful*. :)
Quote:Original post by caldiar
I believe he meant
Python is a scripting language.
C++ is a programming language.


Last time I checked, you could program with Python.

Prehaps we all mean "C++ is a compiled language."?

@OP - Since your original question was rather vague, I'll just say something on the topic of Python and C++. Recently, I've been adding Python to my C++ game as a scripting language. It's been difficult, but definately doable. It seems to be working fine now and I started embedding it about two weeks ago, IIRC. It's quite nice being able to write a script and forced me to provide a nice abstraction layer between my Entity class and the game logic.

This topic is closed to new replies.

Advertisement