1. <script type="text/javascript">
  2.  
  3. function makeArray() {
  4. var country = new Array(5);
  5. country[0] = "Austria";
  6. country[1] = "Canada";
  7. country[2] = "France";
  8. country[3] = "Germany";
  9. country[4] = "Switzerland";
  10. return country;
  11.  
  12. var villages = new Array(2);
  13. villages[0] = "Austria:Seefield 850m*";
  14. villages[1] = "Austria:Ellam 100m";
  15. return villages;
  16. }
  17.  
  18. function snowReport(countryIndex){
  19. var string = "";
  20. for (var i = 0; i < countryIndex.length; i++){
  21. str += countryIndex[i] + " ";
  22. }
  23. return str;
  24. }
  25. </script>
  26. </head>
  27. <body>
  28. <script>
  29. var x = makeArray();
  30. document.write(snowReport(x));
  31. </script>
  32.  
  33. </body>
  34. </html>