Employers: discover CodinGame for tech hiring
CodinGame_Logo_Final_Full
ACTIVITIES
PRACTICE
COMPETE
LEARN
COMMUNITY
CONTRIBUTIONS
LIVE STREAMS
DISCORD
FORUMS
BLOG
Get a job
1
Log In
Sign Up
Another User Conversion
Anonymous
1,475 views
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
#include
<iostream>
using
namespace
std
;
class
Person
{
public:
Person
(
const
char*
stName
)
{}
const
char*
GetName
()
const
{}
// this is needed for cout << person
operator
const
char
*()
const
{
return
"John"
;}
private:
char
* m_stName;
};
int
main
()
{
Person
person
(
"John"
);
cout << person << endl;
foo
();
return
0
;
}
Run
0
0
Create your playground on Tech.io
This playground was created on Tech.io, our hands-on, knowledge-sharing platform for developers.
Go to tech.io
Suggested playgrounds
SHL
By
Unnamed contributor
1,524
2
0
Range-based for loop
By
Unnamed contributor
1,563
0
0
Python Hello World program
By
SJTECollege
3,673
200
7
Correct the code to display 'Hello World!'
By
SJTECollege
3,899
163
4
CodinGame - Home
ABOUT US
CAREERS
PRIVACY
FAQ
CodinGame - Work
The #1 tech hiring platform
SCREENING
SOURCING
RETAIN
ABOUT US
CAREERS
PRIVACY
FAQ
Facebook
YouTube
Twitter
LinkedIn
FR
EN
Join the CodinGame community on Discord to chat about puzzle contributions, challenges, streams, blog articles - all that good stuff!
JOIN US ON DISCORD
Online Participants
Keyboard Shortcuts:
?
Show / hide this help menu
×