Ok, let me attempt to clarify from a non-developer standpoint. In the declaration of the function mall, you defined item1 as type item; therefore, since it is defined as such, you just need to use item1 instead of '$item[item1]' as shown below. You also forgot to type currentprice in main()...