Hi all,

I've been struggling to learn structures, and I think I've got the structure part down now. I'm trying to create a print function to print what I've put into the structures, and I'm getting all sorts of errors from my compiler. Could someone tell me what I'm doing wrong? Thanks for taking the time to read this.

Code:
#include <stdio.h>
#include <string.h>

struct movie{
	int year;
	int rating;
	};

void print_function (&movie *t);

int main (void)
{

struct movie starwars;

  starwars.year = 1986;
  starwars.rating = 5;

print_function(&movie *t);

return 0;
}

void print_movie(&movie *t)
{
	printf("Year: %d\n", t->year);
	printf("Year: %d\n", t->rating);

}