TuF
Cant understand
I_Interface
<random>
<algorithm> needs too prob ?
Mihail
I want a personal programming tutor...anyone intrested?
No one would teach you for free, but you can teach yourself for free using the Internet
Dima
Lol
IM
I want a personal programming tutor...anyone intrested?
if you're complete noob check CS50 course
Rostin
@KevinKiprich10 I dont mind answering small questions if u have...PM me
Nikolas
Cant understand
you are trying to print a float value as an int
Kk
Thank you
Nikolas
if you want to do that, explicitly cast it
Mihail
@KevinKiprich10 I dont mind answering small questions if u have...PM me
Questions we'll answer, but we won't tutor someone (hold his hand)
Nikolas
Cant understand
you code has undefined behaviour
Nikolas
http://www.open-std.org/jtc1/sc22/wg14/www/docs/n1570.pdf If any argument is not the correct type for the corresponding conversion specification, the behavior is undefined. (page 427) took from here: https://stackoverflow.com/questions/38597274/why-does-printff-0-give-undefined-behavior
数学の恋人
Hey @mmihov, I modified the code like this but the problem is everytime I run I get same string.
数学の恋人
how to do that?
Mihail
Well using srand() would work
Mihail
Or just do it properly
数学の恋人
okay I searched on www
数学の恋人
Well using srand() would work
yeah I got first results like this
Mihail
Which would mean using a random device as entropy to a mt19937 and then putting that in a uniform distribution
数学の恋人
Mihail
Hey I have a doubt can I PM you?
You could ask here so more people can help, but ok
😝😁😝😁😝😁😝😁
I have no knowledge in programming can I get some knowledge here?
数学の恋人
Okay then here, What will happen if I pass a random char to srand (as argument) then that will act as seed and then which in turn again generate another random char
数学の恋人
if chars don't work then some number
Mihail
But you could do it
Rostin
You could pass time(NULL)
Mihail
If you want it to be random then what Rostin said is generally a good idea
Mihail
But rand still has the issue of numbers not being distributed evenly
Mihail
So if you run it many times you might see certain values being more common than others
TuF
I want to do coding But i cant plz suggest something ........
Rostin
Rostin
This is what @mmihov means by uniform distribution if u had any doubts
数学の恋人
why only mt19937? aren't there any other?
Rostin
It's considered to be the best pseudo random number generator available in std library
数学の恋人
Oh
Rostin
Std library has bad generators to begin with, but mt is the best out of the pile
数学の恋人
Hmm...
TiMis
Any one who understand unsigned
Mihail
Any one who understand unsigned
What don't you understand about?
TiMis
The unsigned and signed short and long
TiMis
And how can you add your C++ code to make a software
数学の恋人
What don't you understand about?
https://asciinema.org/a/251755 I got it working
Rostin
🥳
数学の恋人
That's right, right? (This sentence is kinda funny)
Rostin
Cant see ur code
数学の恋人
Cant see ur code
yeah wait I'll link it
Anonymous
Do you have any ideas for any medium size cli projects?
Decoder_3d
I use geany
Yeah I used this one also good :)
Anonymous
Hi How can i send some value in one dimensional array into two dimensional array? (c++)
Artur
Hello everyone! I've in plans to learn Pure C (Maybe some C++). Currently, I'm an Android developer. Have good knowledge in Java. Also, I know a bit of Python. I'm using Linux as my main operating system. I want something fast and simple because the overhead that we have in using Java is pretty big. I really need advice from people who are working with C, how to learn it better and more practical. There will be few points and I will really appreciate if you'll share any of your ideas about them. 1. I've heard a lot about that is better to use old C90 standard. Correct me if I'm wrong. 2. I'm interested in writing good quality code from the beginning, so I will appreciate any checkstyles or checkstyle checkers what people use. 3. Also, I have a question about what IDE is better to use. I've used CLion a bit and also used vim but without any additional plugins. 4. Probably I will start my learning by creating some game on SDL (probably second version). If it's a bad idea tell me why. P.S. Also if you have any information or ideas that are not about something in this list, share them, please. Thank you in advance.
Dima
vs code for c o.O sounds awkward
Jeremy
I dunno, just an idea for easy features.
Anonymous
hello
Rostin
Hi
Anonymous
I just begin to learn c++ for several mouths in uni. I want to know will i use it in my work? Maybe python is more usual
Avezy
Depends on your employment
Anonymous
Which is more important? Python or c
Rostin
Depends on your job
Rostin
😂😂😂
Anonymous
Ok
Anonymous
Which is more important? Python or c
In what way? Competitive programming or general learning
Avezy
Some jobs more python or even other languages other jobs c++
Avezy
Some companies might have build systems relying on python for example
Anonymous
General learning maybe
Anonymous
Oh i see
Avezy
but you code in c++
Anonymous
Competitive program C++ but nowadays Python is also more coming up using pypi