Here\'s my code:
#include using namespace std; int main() { void *x; int arr[10]; x = arr; *x = 23; //This is where I get the error
you cant derefrence void*, and that is what the coder is doing.
*x = 23; // this cant be done with void*
instead :
x = &arr[index] ; // this is correct