fan
In fact, IDE is not necessary. Someone use vim or emacs also coding.
fan
If you use windows os. maybe the WSL is a good choose.
Blyncnov
winlibs.com for gcc and g++ vscode as code editor
I guess I should stick with vscode
Blyncnov
Thanks 👍
fan
I guess I should stick with vscode
macos is ok, homebrew install gcc / clang. And because the visual studio in mac is not better than windows.
fan
compile it in your terminator.
Hussein
I guess I should stick with vscode
visual studio is for windows only
Hussein
visual studio code (VScode) is cross-platform but it’s a text editor so it doesn’t compile your programs for you, you need to install a compiler on your system
Hussein
I am using it with a c++ extension and code runner
yes but you still need a compiler for the extension to work there is one called clang that I think will work the best for you
Blyncnov
Working for me
Hussein
ok then compile your programs with: clang file1.cpp file2.cpp file3.cpp then to run them: ./a.out
Hussein
I have that installed ..
write this ☝️ in your terminal then press enter
SR27
#include <stdio.h> #include<stdlib.h> int main() { int *a[10]; a[3][2]=5; printf("Hello World"); } how a[3][2] is possible ? not giving any error also printing hello world
SR27
no its int *a[10]; in c lang
SR27
onlinegdb
SR27
at compile time ?
The
I have an assignment for c can anyone please help
The
Tomorrow is last date
klimi
I have an assignment for c can anyone please help
What happened that you haven't finished it before? What are you struggling with?
The
I was absent in class due to illness.
The
And I am very weak in c programming
o
And I am very weak in c programming
https://letmegooglethat.com/?q=malloc+in+c
fan
#include <stdio.h> #include<stdlib.h> int main() { int *a[10]; a[3][2]=5; printf("Hello World"); } how a[3][2] is possible ? not giving any error also printing hello world
the in* a[10] means a pointer nums, every elemens in nums is a int*, and here you define a in* a[10] in stack memory place. you don't init it. but you assign a[3][2] , a[3][2] means the nums of second pointer and offset two sizeof(int) address,
fan
you assign a no init memory is a undefined behavior in C / C++ progma.
Paul
No
ᴴᴼᴹᴮᴼᴷᴺᴵ
hey guys , i am new c++ programming can anyone helps me with a free website or a youtube channel .
/
someone know what is the difference between open() and syscall( open number )
Sina
I have a problem I gotta send a picture to show it can anyone help ?
Subhash Suthar
brother can i get c programing basic study metrials
Riya
What is oprating system
Riya
And plzz give me a study material
Dima
not being rude, but if you dont even know what is OS, why are you studying it
S
Does anyone give oracle coding round?
Ali
Protocol Decoding program in c/c++?
Hussein
radare2 is a really good option ghidta is more popular and considered more professional ida is expensive and less powerful (but it has easier to use gui tbh) there is a one called plasma thay generates pseudo-code and it is easier than the previous three
Hussein
all require some knowladge in assembly
note that ghidra decompilation is known to be better
Hussein
well ida is okay but eventually you will end up learning to work on more than one framework each one has it’s pros and cons if you started with ida then don’t switch to any other framework unless you become more proficient with it
Anonymous
hello, looking for low level C enthusiastic to chat with. interests embedded, micro systems, all unix and system V flavors or unix and linux. currently ive found a curiosity statically linked executable and the shrinkage of them. wondering if anyone has had much experience with tools or strategies of shrinking a code base even further than the normal optimizations and stripping (gcc arguments and strip arguments)
Anonymous
love looking at old school programming projects where they were hardware constrained such as sub 100kb game ROMs and early computer programs, so much code, so little space/size
SR27
#include <stdio.h> #define print(x) printf("%d ",x) int main() { int z=10; print(z); int x=5; print(x); }
SR27
i think it should give error because of print(z) but it is not giving its so my question is how print(z) is replaced by printf("%d",z); when i have define print(x) printf("%d",x);
SR27
how x is replaced by z
Anonymous
thats just the macro variable name
Anonymous
when you pass a variable type or pointer to a function or processor macro, the name you use it as in the function/macro does not matter
Anonymous
as long as its of the correct type, and if multiple arguments as long as the order of the types are in correct order it should not matter what they are called
Anonymous
the program isnt seeing you pass the human friendly letter X, its seeing a computer address, that name you see is just in the programming language to help the human understand notice how the value is the same? regardless of what var name you use? try the same, but pass a pointer and print the pointers address, maybe that will help you understand
Anonymous
:)
𝑪𝒐𝒃𝒓𝒂
Hi, I am a newbie to c++ and I am not able to move ahead from functions and structures that are irritating me a lot how can I deal with it and know it better?
Pavel
Hi, I am a newbie to c++ and I am not able to move ahead from functions and structures that are irritating me a lot how can I deal with it and know it better?
Why are you not able to move ahead, is it something specific that you need to understand but have trouble with, or something else?
Anonymous
Hi, I am a newbie to c++ and I am not able to move ahead from functions and structures that are irritating me a lot how can I deal with it and know it better?
First, have more hands on the language with basics like arithmetic operations, loops, if/else, then go on structure and pointers. It'll take time initially.
𝑪𝒐𝒃𝒓𝒂
𝑪𝒐𝒃𝒓𝒂
Anonymous
Just look on online resources, books or you can try on hackerearth, codechef.
Anonymous
hello guys
Anonymous
switch (choice)    {    case 1:    {        // INSERTING NEW SONG IN THE PLAYLIST         cout << "\tEnter the song you want to add in your playlist: ";         std::getline(std::cin, songTitle);         song* newSong = new song;         newSong->data = songTitle;           playlist = insert(playlist, newSong);    break;    }       case 2:    {        // REMOVING SONGS IN THE PLAYLIST         cout << "Enter the song you want to remove in your playlist: ";                 std::getline(std::cin, songTitle);     
M
#include<iostream> #include<string> using namespace std; int main(){ string s; cout<<"enter any binary num"<<endl; cin>>s; for (int i = 0; i < s.length(); i++) { if (s.at(i) == '0') { s.at(i) = '1'; } else { s.at(i) = '0'; } cout<<s.at(i); } }
M
#include<iostream> #include<string> using namespace std; int main(){ string s; cout<<"enter any binary num"<<endl; cin>>s; for (int i = 0; i< s.length();i++ ){ if (s.at(i) == '0' ){ s.at(i) = '1'; } else{ s.at(i) == '0'; } cout<<s.at(i); } }
M
this two are binary conversion program... but both work differently i dont know why?
M
one converts successfully (bcz i copy pasted it from tutorial )..but one dosent (which is made by me 😭)
Manfred
Look at == and =
M
same it is.. im i missing something?
Ludovic 'Archivist'
same it is.. im i missing something?
No, = and == are not the same. One is an assignment, the other is a comparison, respectively
M
#include<iostream> #include<string> using namespace std; int main(){ string s; cout<<"enter any binary num"<<endl; cin>>s; for (int i = 0; i< s.length();i++ ){ if (s.at(i) == '0' ){ (is it this line?) s.at(i) = '1'; } else{ s.at(i) == '0'; } cout<<s.at(i); } }
M
thanks..... now i get it
Nomid Íkorni-Sciurus
How do you link dynamically to a shared library with conan+cmake? I've tried anything but the docs were unhelpful.
sushi
Thank you
Ya deway
Sorry, i would ask if code ofuscation work for protect source from reverse engineering (assembly), like read strings or functions