0

I remember seeing somewhere that you could call python methods from inside C using

#include "python.h"

But I can't seem to find the source for this or any examples.

How can I call python methods from inside a C program?

2

2 Answers 2

5

Here's a doc item from the python site about extending C with python functionality

Here's the start of the documentation (where it refers to python.h) where you can extend Python with C functionality.

Sign up to request clarification or add additional context in comments.

Comments

2

Check out http://docs.python.org/c-api

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.