Copy and paste on certain cells based on index

Here's the setup:

Sheet Two contains two rows of data.
Row 1 contains the index of the value in row 2, ex:
1           2        3         4     etc....
0.23    0.34   0.61    0.12

Sheet One has a row of indices, ex:
2     4     9    etc...

I need a script/formula to copy the values for the indices in Sheet Two to the appropriate indices in Sheet One, ex:
Sheet One after script:
2           4      etc....
0.34    0.12

Need more info?

Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Patrick MatthewsCommented:
Try hlookup:

=hlookup(a1,'sheet two'!$1:$2,2,false)
NorieAnalyst Assistant Commented:
If you want a formula you could try INDEX:

=INDEX(Sheet2!$2:$2,, A1)

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
christamccAuthor Commented:
I forgot to mention that the index is not the header row and I could have multiple rows of indexes on a sheet, so HLOOKUP wouldn't work for my situation, but I was able to get INDEX to work.

It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Microsoft Excel

From novice to tech pro — start learning today.