hello I'm chinese

I am study c language for two mouthes.
Could you(admin) send some windows program source code to me?
thankyou very much.
Last edited on
I think that you can search it in google,something online.
Shure why the hell not!!! this one is "Python"!!! Comonly used but i was able to find it as a "cpp" file. i use DEV-C++ to compile it.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
/******************************************************************************\

	Title:
		Simple Python Interpreter

	Description:
		This is an example of a simple Python interpreter.
		Note that you must copy python24.dll from the Dev-C++/DLL
		to where this program will be built.

	Author:
		Rob Loach (http://www.robloach.net)
	
	Date:
		March 22, 2005

\******************************************************************************/


#include <iostream>
#include <string>
using namespace std;


/*
	Include the Python library
*/
extern "C" {
	#include <python2.4/Python.h>
}


int main(int argc, char* argv[])
{

	/*
		Initialize Python
	*/
	Py_Initialize();


	/*
		Display Python version information and some help
	*/
	cout << "Python " << Py_GetVersion() << endl << endl << endl;
	cout << "Type in some Python script. Type 'exit' to quit." << endl;


	/*
		Start the interpreter
	*/
	string input;
	while(input != "exit"){
		cout << ">> ";
		getline(cin, input);
		PyRun_SimpleString(input.c_str());
	}


	/*
		Finish up
	*/
	Py_Finalize();		// Close Python

	return 0;
}
I don't understand what you mean , do you have any problems in you C learning? please make it clear.
usherpp: justinzhang has only a single post, and it was in January. I don't think he's ever coming back. I'm afraid it was a waste of effort to bump this thread after a month and ten days of inactivity. Sorry, man...
Look for a classic book, and parctice!
Code is from writing not reading!
Topic archived. No new replies allowed.