Posts by Walisson • 51 points
4 posts
-
0
votes1
answer72
viewsQ: Class definition
When I studied about defining a class it would be like this in the header: class Jogador { int id; std::string nome; int vida; void setNome(); std::string getNome(); } However I am seeing a little…
-
1
votes2
answers80
viewsQ: Use extra space in addition to that reserved by "malloc"
When we request an amount of memory from the system and use much more than requested, what happens? I did this test and the code here compiled normally. At first it worked as it should, I wanted to…
-
1
votes1
answer99
viewsQ: Memory pointer and allocation
I know which pointer stores memory address. And a variable stores a value. But taking into account that I have a class class player {} and create a variable player p; and an instance of a pointer…
-
0
votes1
answer66
viewsQ: For syntax without the counter
I am a beginner in programming and I am studying the C++ language, therefore it is also my first time using this site. But after doing a basic course on the mentioned language, I downloaded a source…