Display an array of inputs in javascript

hello again… I keep having trouble with this java script.
So… I have a form with multimple input text that send the data as an array like this:

key1: <input type='text' name='keywords[]'>
key2: <input type='text' name='keywords[]'>
key3: <input type='text' name='keywords[]'>
key4: <input type='text' name='keywords[]'>
etc..

The idea is that I need a confirmation dialog to ask the user something like “are you sure that key1, key2, key3 are correct” and instead of key1, key2 i need to display what he’s typed in. I did not manage to do this by form.keywords[].value and did not find any other solutions.