Hi guys,
I'm just a very beginner in coding. I would like to do the following tasks.
I have a text file named "list.txt" which is located in http://demo.com/list.txt
The content of the text file is:
person_a, 100
person_b, 200
person_c, 300
In my script, I have a variable named: $person = "person_b".
Is there anyway I can check if "person_b" exists in the "list.txt" file? And if it exists, how can I get the number next to it (which is 200)?
Thanks a lot for your help!