For an assignment I have to create a linked list.
I have to read from an input file and save the contents to a linked list.
But before that I want to ask for advice which approach would be wiser.
The Input file looks something like this.
Jake 21
Mark 22
King 34
William 25 and so on.. in total I have 26 names with age.
I have looked up linked lists.
|data |217| | data |218| |data |NULL|
So I have data with the adress of the next nodes.
My guess is that for each nodes I store name and age.
However I have 26 Names in the input file should I create 26 nodes?
Would that make any sense or am I completely on the wrong track?
I apologize if this is a stupid question, but I have been looking for tips on the internet for hours and I can't seem to find a sensible approach.
I have just come up with a soloution ignore this post sry https://cboard.cprogramming.com/imag...lies/smile.png