C Language Basics
storage and memory
arrays and strings
conditionals and looping
other
debug (challenge mode)
100

A keyword used in a function definition that means the function returns nothing.

What is void?

100

This part of memory stores temporary data and grows toward the code section

what is the stack?

100

This type of data structure stores multiple values of the same type in sequence.

What is an array?

100

This keyword is used to execute a block of code only if a specified condition is true.

what is if?

100

The first step in writing any C program

What is planning/psuedocode/algorithm design?

100

find the problem

if (x = y) {
   printf("Equal");
}

we need to use == to do a comparison 

200

A line of code that includes the Standard Input/Output library.

What is #include <stdio.h> ?

200

This is the name for the unique location assigned to each byte in memory.

What is an address?

200

This is the index of the first element in a C array.

what is array[0]?

200

This operator checks if two values are equal.

what does == do?

200

This type of language translates all code to machine language before execution.

what is a compiled language?

200

while ( i < 5);
{
    printf("%d\n", i);

    i++;
}

the loop is punctuated early with a semi-colon, so i will never increment, and while will continue

300

A variable that can only be accessed within the function it's defined in

what is a local variable?

300

This type of variable retains its value between function calls.

What is a static variable?

300

This is the syntax to access the third character in an array/string named name.

what is name[2]?

300

This loop always runs at least once, even if the condition is false.

what is do while?

300

Programming for an application that is simple, repetitive, requires low power and low memory, and may not support native development

What is embedded programming?

300

if (digitalRead(buttonPin) = HIGH) {  // do something
}


this line is supposed to trigger when a button presses, but it never works, what's wrong?

used = instead of ==

400

This is the term for the mini-definition of a function placed at the top of the code.

what is a function prototype?

400
A variable that takes up 8 bytes of space

what is a double variable?

400

the term that indicates which element in an array you wish to access

what is index?

400

This type of loop is ideal for checking sensor input until a threshold is reached.

what is a while, polling, or event loop?

400

This is the correct way to declare a pointer to a character (char variable)

char *pc = &x

400

find the problem

char word[5] = "hello";

the array is too small to contain a null terminator

500

Tells the program to put aside a space in memory of a certain size and give it a name so that data can be saved to or copied from it

What is declaring a variable?

500

names that use special characters, spaces or keywords such as

calidonia's Arduino

float

*answer*

X!

What are some unacceptable variable names in C?

500

on the board! (or in chat)

declare and array called student of 10 chars, and store the name of a classmate who is not on your team in the array, 50 bonus points if you get their last name too.

what will this code do? 

char student[] = {"Manolito Funderburg"};

500

*ON THE BOARD* (or in chat)

You want your microcontroller to turn on an LED only if the temperature is above 30°C and the humidity is below 40%. Write the conditional statement that would achieve this.   

(just give me the initial conditional statement, no need for a full program just one line with the conditions)

if (temperature > 30 && humidity < 40 )

500

given the code:

char a = 10;
char b = 20;
char *ptr = &a;
*ptr = b;


what are the final values of a and b?

a = 20 

b = 20

500

find the problem

int *ptr;
*ptr = 10;

a pointer needs to be set to an address, this is called de-referencing and uninitialized pointer