I would like to study C using iPad. Just simple programs. So, is there a C compiler for iPad?
A cursory look at the iTunes Store reveals CodeToGo (iTunes Store Link). Since you cannot compile on the iPad itself, this app leverages a web service (IDEOne) in order to run the program and return the results to your device. The app is USD$3 and a universal binary (iPhone+iPad). The web service appears to be free, if not just a little ugly :).
If you have an internet connection, you could use codepad.org. They let you compile many different languages from code you paste into a web form. Supports a lot of formats and has some nice sharing features.
If you're willing to jailbreak, the answer is yes. You can install GCC (the same open-source C compiler included with XCode) on your iPad.
The process is a bit complicated, but it's certainly possible. You can find instructions here. The instructions I've linked only mention the iPhone, but the same process should work on the iPad.
If you're not willing to jailbreak, then the solution VxJasonxV suggested might be your only option.
There are no C compiler App Store apps for any iOS device due to a clause in the iOS Developer Program License Agreement which basically says that:
"Apple's iOS SDK prevents any software on the iPhone from downloading or running external executable code"
That is taken from wikipedia. I believe I can't link to the agreement for some reason or another.
If you just want an editor you might look at Project Edit.
EDIT: Looks like the terms were updated but maybe only interpreted code is allowed like what the Pythonista app does for Python but not for compiled code.
The CppCode ios app supports code-complete and does not require jailbreak and internet connection
PowerC++ is an alternative to CPPCode if your iPhone does not support iOS 8 which CPPCode requires. But PowerC++ only uses a C++ Builder installed in a DOS environment customized for iOS. It seems a bit out of date and doesn't support newer versions of the C++ standards. Caution: it works fairly well most of the time but collapses on the invocation of a few of its functions. In addition, the font size may appear too small and can't be enlarged.
I have stumbled upon this C/C++ compiler; not sure what it's worth though but it does look like a simple-ish C/C++ compiler for iPhone/iPad.
My guess is that it does not actually compile to iOS binary code, but to some sort of bytecode that the program then interprets. That's the only way it could get by Apple QA.
Actually you can just go to compileonline.com You can use any programming language on this site, for free!
Enjoy Online Compilation
Just follow the following simple steps to compile and execute any of your favorites programming languages online using your favorite browser and without having any setup on your local machine.
Step - 1 Select your favorite language which you want to execute.
Step - 2 Type your source using available text editor.
Step - 3 Finally click compile button [ Ctrl+E on Windows & Command+E on Mac ] to see the result.
This is an integrated development environment which runs on a virtual ubuntu in your browser. Works well.