Pointer assignment

Hello

I was given an assignment by my teacher to help us with pointers and functions before our next test. The problem is that I am having huge issues understanding these topics.

I have attached the assignment and all that I have coded out so far. Any help, explanations, links to tutorials would be greatly appreciated.

Thank you.

void explainProgram(void) {
  Serial.print("--Amperage calculator--\n\n");  
  Serial.print("This program calculates the amperage\nthrough a resistor given voltage and resistance.\n\n");
}

void getValues(float *ohms, float *volts) {
  
}

float doCalculations(float res, float *volt) {
  
}

void displayAnswer(float amps) {
  
}

void setup() {
  Serial.begin(9600);
  explainProgram();
}

void loop() {
  
}

Assignment1.pdf (51.3 KB)

do u have a schematic of what u are doing.. kinda tuff otherwise......

backwoodsjack:
do u have a schematic of what u are doing.. kinda tuff otherwise......

Here you go:

V(+) ----////---- V(-)

You must use the following prototypes: (Do not alter their parameters)
void explainProgram(void);
void getValues(float *ohms, float *volts);
float doCalculations(float res, float volt);
void displayAnswer(float amps);
You have at least the following variables:
float resistor, voltage, current;
No global variables are allowed.

Interesting. The problem is in the last line.

If it's a school assignment, you should do more before asking for help here, though. What you posted isn't even an attempt.

aarg:
If it's a school assignment, you should do more before asking for help here, though. What you posted isn't even an attempt.

This is because I don't know how or where I should approach this assignment.