Ritax
I'm quite new to programming and i had chosen c++ for competitive programming. Can anyone give me any tips how to get started
JoyfulTyrant
I'm quite new to programming and i had chosen c++ for competitive programming. Can anyone give me any tips how to get started
Learn the basic syntax and stuff like loops and everything, you can try learning from a good book, there are plenty.
JoyfulTyrant
You can use YouTube too
JoyfulTyrant
After that learn Data Structures and Algorithms, you should know how each and every data structure is represented using c++
JoyfulTyrant
Then learn STL, it's a library of c++ that helps in competitive programming
JoyfulTyrant
YouTube is the best teacher man
Ritax
Thank you so much for the help
olli
YouTube is the best teacher man
Although, there a lot of bad teachers on youtube
JoyfulTyrant
Thank you so much for the help
Anytime man, just know that data structures and algorithms are the two most important things, anyone can learn a language but mastering data structures and algorithms is the best thing you can do for competitive programming
JoyfulTyrant
I wouldnt recommend using a book if you are a beginner as they discuss really complex stuff there, however if you really want to learn through a book, you can get the pdf of 'Data Structures and Algorithms Made Easy' online, they discuss from the basics
JoyfulTyrant
YouTube is the best but not every teacher is great, be careful who you are learning from
JoyfulTyrant
And master pointers in c before learning data structures, without pointers learning data structures in c is useless
JoyfulTyrant
memory management techniques, LRU cache can do the tricks also, as well as red-black trees, DFT, FFT
You are right, I didnt mention them because they are quite advanced 😅
Gulshan
do this both the blocks should be written in the code ?
Gulshan
https://github.com/Microsoft/cpprestsdk/wiki/Getting-Started-Tutorial
Gulshan
error: conversion from ‘task<web::http::http_response>’ to non-scalar type ‘task<void>’ requested
su
what should I do ??
what are you doing? i build all ok
su
git submodule update --init cmake . make
Gulshan
I actually trying to run the code written in code blocks
Gulshan
what are you doing? i build all ok
I am getting an error regarding the variable or something names Request
su
I am getting an error regarding the variable or something names Request
are you trying to build library or error in usage?
su
I am getting an error regarding the variable or something names Request
i build lib ok before use, then will add this git library as submodule for my project
su
I am getting an error regarding the variable or something names Request
you didn add library as cmake target or source path for input and library paths, read readme.md follow instructions
Gulshan
by zypper command
Gulshan
u r in mac, then you can use brew commands... its ok right?? or I have to use cmake then also?
Gulshan
Anonymous
In old C code I see people #define simple if statements or lines of code a lot, rather than say static inline I wonder to myself, is this practice not all but dead now ? Surly now a compiler would be better to decide on it's own? Would a define be more likely to be inlined by the compiler than an inline function ?
Anonymous
#define UC (unsigned char) #define ISDOT(c) (UC(c)[0] == '.' && ((UC(c)[1] == '\0') || (UC(c)[1] == '/'))) #define ISDOTDOT(c) (UC(c)[0] == '.' && ISDOT(&((c)[1])))
Anonymous
https://florenfile.com/iuo61hwlueub/Learning_Serverless_-_Jason_Katzer.epub
Anonymous
how download?
su
u r in mac, then you can use brew commands... its ok right?? or I have to use cmake then also?
i build clean master branch separateley, before integrate to my projest to make shure all works, i already sent to you commands to run main issue is that if you add it as subprject you have to initialize cpprest project submodules
su
this is my brew list:
Gulshan
Do my all programs will work fine.. or I should build them only in the project??
Gulshan
git submodule update --init cmake . make
After cloning the repo right ??
Dark
Hi When we use (HeapAlloc/HeapFree) instead of (New /Delete)?
Gulshan
the only error I am getting is due to that requestTask... please do check
Gulshan
i guess repo is not maintained.... is it a problem ?
olli
i guess repo is not maintained.... is it a problem ?
the last commit was 2 weeks ago, why shouldn't it be maintained?
Gulshan
the last commit was 2 weeks ago, why shouldn't it be maintained?
hmm.. I didn't seen that.. but there are very less replies to the issues raised
Niko
Hi When we use (HeapAlloc/HeapFree) instead of (New /Delete)?
(heapAlloc/free) for win? (new/delete)for std Cpp?
Gulshan
hmm.. I didn't seen that.. but there are very less replies to the issues raised
by the way is it good to handle these request thing with cpp or I should use python? which one will be good for me... in terms of learning
su
i guess repo is not maintained.... is it a problem ?
16 Days ago? all was fixed in PR, recenlty. what do you call not maintained?
Gulshan
su
just changed the answer and agreed my mistake sir
ok. why you use 2 request libs together?
Gulshan
its given on their get started page.. they said to copy paste in your code
olli
Hi When we use (HeapAlloc/HeapFree) instead of (New /Delete)?
https://docs.microsoft.com/en-us/windows/win32/memory/comparing-memory-allocation-methods
su
its given on their get started page.. they said to copy paste in your code
how you gonna convert request stream into taks, BTW?
Gulshan
i am getting an error
su
i am getting an error
which libs do you have installed in brew?
Gulshan
how you gonna convert request stream into taks, BTW?
I am following the code given on the page... I don't know anything about how to use requests in cpp
Xudoyberdi
https://pastebin.com/Vhice7VC
Gulshan
Xudoyberdi
https://pastebin.com/Vhice7VC
i am trying to find one value in array but error occurs
su
should I uninstall them ?
do you have boost in brew list
Gulshan
no...
su
no...
install all i have in brew list then retry
Dark
(heapAlloc/free) for win? (new/delete)for std Cpp?
@ollirz send link, Good explain that @ollirz thank You
Anonymous
macro is inlined by preprocessor(and its always done), does C have inline function at all?
C does have inline, but even if it's inlined in the pre-processor what are the chances that the compiler will still inline it
Alex
compiler knows usually better to inline or not
su
C does have inline, but even if it's inlined in the pre-processor what are the chances that the compiler will still inline it
chances equals to chances setup proper optimization and inlining optinons for the compiler
Xudoyberdi
Niko
Anyone can help
The 5 line ,'char names[3]' should be 'char names[3][10]'.you should use two dimensional array save the three word.'char names[3] only can save 3 character'
Gulshan
Anyone can help
Can you use c++ if your instructor allows you... If yes then use string header file...it works like a charm
Anonymous
https://pastebin.com/Vhice7VC
Read a book before writing code
Xudoyberdi
But lemme try
Anonymous
But lemme try
You don't understand the basics