Hi, im new here and also new to C++ (pretty much new to programming anyways)

I have been working in an assignment and got stuck trying to store information into a 3x3 array, and then retrieving the data.

#include <iostream>
#include <iomanip>
using namespace std;
int main()
   float num[3][3];

   cout << "Enter 9 numbers: ";
   for (int i = 0; i < 9; i++)
		cin >> num[3][3];
   cout << num [4]; 

the program runs fine and accepts the input of 9 digits, however when trying to display some of the data it just gives a weird code composed of numbers and letters, I'm trying to store the data and then use it for other operations but cant go further without making sure that the data is correctly added to the array. (the array must be 3x3 according to my assignment)

wow thanks, that was fast, now i can recall any piece of data from the array with ease, thanks!

This question has already been answered. Start a new discussion instead.