In member function 'void Test::get()':
21:8: error: no match for 'operator[]' (operand types are 'Test' and 'int')
In member function 'void Test::show()':
28:10: error: 'i' was not declared in this scope
Line 21 does not read into "this". It attempts to read into global object 't'. Why?
Line 28 attempts to access same global 't', and has name 'i' that we know nothing about.
Why is the 'name' an array or char? You would probably be better off with single std::string.