Hey I've a dynamic array and I want to load to this array the data of my Wav file, I already wrote the beginning but I can't figure it out how to load the file in my dynamic array, can somebody help me further with this code?
#include <iostream> 
using namespace std;
template <typename T> 
class Array{
public:
    int size;
    T *arr;
    Array(int s){
    size = s;
    arr = new T[size];
    }
    T& operator[](int index)
    {
        if (index > size)
            resize(index);
        return arr[index];
    }
 void resize(int newSize) { 
        T* newArray = new T[newSize];
        for (int i = 0; i <size; i++)
        {
            newArrayi] = arr[i];
        }
        delete[] arr;
        arr = newArray;
        size = newSize;
    }
};
int main(){
    Array<char> wavArray(10);
    FILE  *inputFile;
    inputFile =fopen("song.wav", "rb");
        return 0;
}
 
     
    