what are the basics to translate C PRogram in processing code?

edited March 2014 in General Discussion

example like this for ( a=1;a<=10;a++) for(b=1;b<=a;b++) printf("%d" , a*b);

Answers

  • for (int a=1;a<=10;a++) {
      for (int b=1;b<=a;b++) {
        println(a*b);
      }
    }
    
  • The basic is to learn both C and Java, probably...

    But syntaxes are similar, particularly in the code snippet you show.

  • but i have a exam after 1 week how can i learn C language now? :/

  • I don't get it. Is your test about converting C code to Processing/Java??? :-??

  • It's not that hard

    Did you do this:

    http://www.learn-c.org/

    Unfortunately this is not a C but a processing / Java forum

    But there are of course further resources

    Best might be to play around with small code pieces; do you have a C or C++ or C# program where you can write and run your code in?

  • The basics are: 1) Be able to determine from code in one language what that code is doing. This requires an understanding of the syntax of the first language. 2) Write code that does the same thing in the second language. This requires knowledge of the syntax of the second language.

Sign In or Register to comment.