I am not too experienced with the nesC programming language at the moment. This document will go over my knowledge of the nesC language so far.
This document used version ? of the nesC programming language. The version will be listed with each example.
Comments in nesC are similar to languages lika C, C++, C#, Java, JavaScript, Google Go, etc.,
// This is a single line comment
/* This is
a multi-line
comment */
This example works with every version of nesC.
nesC supports the break
keyword:
break
To this day, I am still not entirely sure what the break
keyword does, but most languages support it.
A hello world program in nesC is similar to a C hello world program, as nesC intends to be an improved clone of C,
interface hw() {
printf("Hello World\n");
}
This example works with every version of nesC.
/!\ This example has not been tested yet, and may not work
nesC commonly uses the interface
keyword. It is similar to using int main
and is used like so:
interface nescinterface() {
printf("Welcome to my nesC program!\n");
break
}
This example works with every version of nesC.
/!\ This example has not been tested yet, and may not work
nesC supports the return
keyword. It is used like so:
interface returntoSender() {
printf("Return to Sender\n");
break
}
return returntoSender();
break;
This example works with every version of nesC.
/!\ This example has not been tested yet, and may not work
nesC supports the read
keyword. I think it is used for reading files, but I am not sure. I feel that is what #include
is for.
Here is how I have been using it:
read(main.nc)
This example works with every version of nesC.
/!\ This example has not been tested yet, and may not work
nesC, like C, supports including header files. It is used like so:
#include <header.h>
#include <header.nc>
This example works with every version of nesC.
/!\ This example has not been tested yet, and may not work
nesC supports the char
keyword for defining characters. Here is how I have been using it:
char("String character");
char("UTF-8");
This example works with every version of nesC.
/!\ This example has not been tested yet, and may not work
nesC supports the int
keyword for defining integers. Here is how I have been using it:
int y = 10;
printf(y);
This example works with every version of nesC.
/!\ This example has not been tested yet, and may not work
Like most programming languages, nesC supports if
and else
statements, and they are used like so:
// If/Else statements in nesC
char s = "x is greater than y";
char t = "y is greater than x";
int x = 7;
int y = 10;
if x > y
return s()
else
return t()
This example works with every version of Elm.
/!\ This example has not been tested yet, and may not work
The majority of my nesC knowledge comes from self-experimentation, and Wikipedia. Self experimentation didn't go far, and unfortunately the majority of knowledge currently comes from Wikipedia. I wanted to make source code more original, but there isn't any other way I would have written it.
-
nesC is a curly bracket and semicolon language
-
nesC is a C-like programming language designed for the TinyOS operating system
-
nesC uses the
*.nc
file extension -
nesC is spelled with all lowercase, except for the last letter. It is not to be spelled in any way other than this, even at the start of a sentence, or in an ALL CAPS RANT.
-
nesC is a language recognized by GitHub
-
nesC is an open source programming language.
-
No other knowledge of nesC at the moment.
File version: 1 (2022, Tuesday, April 19th at 3:25 pm PST)