+ 2
Anyone supports this idea for sololearn C++ codes?
EDIT: THIS SUGGESTION IS FOR PUBLISHED SOLOLEARN CODES. So, in order for you to optimize the code sharing and displaying functionality, wouldn't it be a good idea to save the compiled version of the code, for future. e.g. A programmer publishes a code, it gets compiled. A programmer saves new functionality to the code, it gets compiled. A viewer runs the code, and it references to the latest compiled version. Instead of it just getting compiled everytime it runs.
9 odpowiedzi
+ 1
@Timon Pablick
What do you think of the idea though?
0
@Timon Pablick
Are you sure? Compiling a CPP code takes about 2-5 seconds on my laptop.
There's no time difference, when I edit and run, compared to just executing a published code.
0
@Timon Pablick
I'm not sure if you understand what I mean, but here is a prove that the code gets compiled always when it's executed, instead of only when the publisher updates it. Feel free to execute it multiple times to see that the precompiler replaces the macro everytime.
https://code.sololearn.com/ccMW3BuFDu6e/?ref=app
0
That's exactly what I mean, sorry if I wasn't specific enough. I meant that should be implemented over to Sololearn app. Then published codes are actually ran more efficiently.
0
It's great, it makes everybody see how efficient c++ is.
- 1
This is a good idea, and this is also how it currently works.
- 1
Absolutely.
Some languages like python are never compiled but just interpreted.
For example java is compiled just in time (like you thought it was the case with c++).
And c++ is one of the languages with code that is compiled before being published.
- 1
Yes, in the code playground. But not in real applications. Do the same thing on your computer and you'll see this is SoloLearn specific.
- 1
Ok. ( :