Hi. I'd like to see if I can join two different string arrays together.
I have these two strings:string[] AdditionalExtras = new[] { "1 - 16” Alloys", "2 - Privacy Glass", "3 - Spare Wheel", "4 - Parking Pack", "5 - SYNC 3 with Navigation", "6 - Winter Pack", "7 - Floor mats", "8 - Boot liner", "9 - Dashboard camera", "10 - Pet travel mat" }; // Any additional extras will be displayed in the arraystring[] ExtrasCost = new[] { "£300", "£250", "£150", "£600", "£600", "£350", "£70", "£61.69", "£284.36", "£264.50" }; // Cost of each extra item
And, I would like them to be displayed like this (if possible):
16” Alloys - £300
Privacy Glass - £250
The prices are already laid out to correspond with each number within the 'AdditionalExtras' array, if that makes sense. So, item 1 will cost £300, item 2 will cost £250 and so on...
To clarify: If the user enters 1 and 2, I would only like those items to be displayed, not the whole list!
I did try to work out a solution on my own, however, nothing I could come with seems to work (my screenshots below should show this). I also looked online for some solutions, but didn't find anything that would've helped me.
Note: I have asked a previous question based on the first array, which can be found here, so I have got the first array working and display how I want to (my code is pretty similar to the answer that was provided).




