\Device\NUL
I meant cpp namespace.. these are not those right?
b-but you said previoulsy namespaces on windows
The
b-but you said previoulsy namespaces on windows
Yes cpp namespaces.. on windows.. because getting a conflict compiler error on visual studio 14 compiler.. when namespace is differentiated by case sensitivity Same code compiled on linux gcc
The
What it said?
C1001 msc1.cpp
\Device\NUL
C1001 msc1.cpp
This one? https://learn.microsoft.com/en-us/cpp/error-messages/compiler-errors-1/fatal-error-c1001?view=msvc-170
Anonymous
Are namespaces on windows case insensitive?
If you are talking about namespace scopes defined with namespace keyword, then yes they are case sensitive as it is required to be so by the standard.
Josam Marenye
Hello guys. Anyone know how to code the game Lost in the Everglades, or have the code, please send it to me. I will really appreciate it. Thanks
Lio
I have learnt most of the Data structure. But I still find it much difficult to solve a problem.Please anyone suggest me how can I improve my logic building and problem solving skills?
DaviChan
I have learnt most of the Data structure. But I still find it much difficult to solve a problem.Please anyone suggest me how can I improve my logic building and problem solving skills?
Building projects where this is relevant and doing tasks on competitive programming sites like leetcode. If you get stuck there are also solutions for many problems. Definitly focus on quality of tasks over quantity. Also looking at old source code. For example the one of doom is a good learning resource (but not an example of good modern code structure)
Danya🔥
There are several ways you can improve your logic building and problem solving skills: 1. Practice, practice, practice! The more problems you solve, the more familiar you will become with different types of problems and the better you will become at solving them. 2. Break problems down into smaller, more manageable parts. This will help you to better understand the problem and identify the steps needed to solve it. 3. Analyze and understand the problem first before writing any code. Make sure you understand what the problem is asking for and what the constraints and assumptions are. 4. Learn and practice different algorithms and data structures. The more you know about these, the better equipped you will be to solve different types of problems. 5. Collaborate with others. Working with other programmers can help you learn new approaches and get feedback on your solutions. Remember that becoming a good problem solver takes time and practice. Keep working at it and you will continue to improve!
Danya🔥
https://t.me/programminginc/494182
As If it's forbidden
Peppe
Someone know how I can find a string in File .txt in c++?
Ziky
Someone know how I can find a string in File .txt in c++?
I sure someone knows. At least the one called google. Try to ask him how to read a file in c++. He will surely give you few dozens of answers and examples.
itsmanjeet
Hey all, can I list static symbols of a shared libraries? nm -D somelib.so with list out all the dynamic symbols or public/ non-static methods in case of C/C++ and As per my knowledge static methods are not visible outside the object file, but I need to know if some specific static method is available in a library. Thing is a list of static methods are shared via public Array
itsmanjeet
yes, and I am stuck in a weird 😅 issue that I need to list the content and verify if some specific function is defined or not
M O H I T
Do you guys have any source from where i can download the source code of prebuild project?
Your senpai : )
Hey any senior developer here from India i need some advice please help me
Chat Boss
Leovan sent a huge message, it has been re-uploaded as a file guys, why MyInt is abstract? class INumber { public: virtual INumber & operator*(const INum..
محمود
Hello there.. What are steps to get a new compiler? I want to update my compiler to c++20. Thanks in advance.
محمود
Hello there.. What are steps to get a new compiler? I want to update my compiler to c++20. Thanks in advance.
I thought if I update code::blocks (my IDE) to latest version (20.03) the compiler would automatically be installed; but that didn't work and now I'm facing a new problem:
محمود
I thought if I update code::blocks (my IDE) to latest version (20.03) the compiler would automatically be installed; but that didn't work and now I'm facing a new problem:
It says: "Environment error" "Can't find compiler executable in your configured search path's for GNU GCC Compiler"
aaw
Is there anyone who can be my mentor? I pay in cryptocurrency and I'm a newbie.
محمود
It says: "Environment error" "Can't find compiler executable in your configured search path's for GNU GCC Compiler"
After digging into the settings I fixed that issue about compiler's path.. Still no c++20 activation check box.
محمود
try using another ide
what IDE do you suggest?
BLESSED
what IDE do you suggest?
visual studio 2022
محمود
visual studio 2022
Hmm.. Thought there would be a solution that doesn't involve moving to another IDE.. Thanks for your response anyway.
Anonymous
I thought if I update code::blocks (my IDE) to latest version (20.03) the compiler would automatically be installed; but that didn't work and now I'm facing a new problem:
Depends on the compiler and your OS. Most people don't understand that IDEs don't always come integrated with a compiler. Some IDEs like CLion and Visual Studio come packaged with the entire build system. Others like Code Blocks, Anjuta, Eclipse and so on don't. An update to an IDE saying it is C++20 compatible means that the IDE can support C++20 development provided a C++20 compiler is available. A C++20 update to an IDE could mean a lot of things. Primarily it involves a language rules server which helps the IDE recognise C++20 code snippets and helps with things like recognising new keywords if any, choosing standards upto C++20 for your project and so on. So when you update Code Blocks to the latest version, this is what you are getting. Separately you must also update your compiler if it is not packaged with your IDE. How you do this depends on your environment. Read the docs corresponding to your compiler and OS to find out how to do so.
Sa
Hey i need Help . I was doing a question on interview bit https://www.interviewbit.com/problems/repeat-and-missing-number-array/ . I tried using Floyd's cycle detection. But It didn't work . Any idea if it can be solved by cycle detection and if not why it can't.
Anonymous
Hey i need Help . I was doing a question on interview bit https://www.interviewbit.com/problems/repeat-and-missing-number-array/ . I tried using Floyd's cycle detection. But It didn't work . Any idea if it can be solved by cycle detection and if not why it can't.
Well the question gives you just an array as input. So I don't quite understand what cycle you are trying to detect unless you are building your own graph or Linked list from the input array. From the question it is clear that they want to test how you work around overflows. So a simple solution would be to sum all the numbers in the array and also sum the squares. If the input is from 1 to n, the sum of the numbers should be n*(n+1)/2 and that of the squares will be n(n+1)(2n+1)/6. For the given input, both the sums would either be less or more. This information should be enough to determine what the repeating and the missing numbers are. Think about it. Now given that n can be as large as 10^5, n(n+1)/2 and also the running sum can overflow. If you cast the ints to a long long and keep the running sum in a long long, it shouldn't overflow
Chat Boss
E30E SHOVKAT E.C.Engineering sent a code, it has been re-uploaded as a file
Nana Bha
please i have a project to submit. It's in c. It's about any story game with no GUI
Danya🔥
Everything
Danya🔥
Both Code Blocks and Sublime are outdated piece of s..oftware that should not be used today
Anonymous
It was last updated in 2020. The engineering team behind it has disintegrated and new updates are no longer being made. So it is not a good choice to continue using it
Danya🔥
VS Code, nvim, Clion, Qt Creator, Visual Studio - ok
Danya🔥
This is actually a childish behavior
Anonymous
Lol. I havent used it. I prefer VS Code for all my development. I switched to it from vim an havent gone back to vim. Initially I used vim key bindings but soon learnt VS Code's navigational shortcuts and prefer VS Code now.
Danya🔥
So you still use GCC3?
DaviChan
So you still use GCC3?
clang gang! 😂
tgm$12
Hi everyone, I am looking for a good source to study C++ but only free from zero. Tnx
Yogin
i want to learn c++
Yogin
how i can
Abod
I want some ideas projects in c++ including multithreading
Anonymous
I want some ideas projects in c++ including multithreading
hello, dm me, i can recommend project with multireading
Shina
Hi everyone pls I’m looking for ideas on c++ projects
DaviChan
Hi everyone pls I’m looking for ideas on c++ projects
there are plenty. /g/ did publish a list of practise projects a while ago. Im sure you can find it online. Otherwise games/game engines are always fun and can be as simple or as complex as you would like. How about a discord bot? There really are unlimited possibilities
Abdelrhman
😡😡😡😡😡
Andrey
Hello everyone! Speaking of the connection between IDEs and compilers (as Madhu today), I'll share my problem too. I've recently updated gcc to the version 9 and then found out that QtCreator doesn't autocomplete properly anymore. I won't go into details now, but I think it relates to the upgrading gcc. Maybe anybody knows how to fix QtCreator's autocomplete? It is really annoying thing when autocomplete stops working.
Danya🔥
Hello everyone! Speaking of the connection between IDEs and compilers (as Madhu today), I'll share my problem too. I've recently updated gcc to the version 9 and then found out that QtCreator doesn't autocomplete properly anymore. I won't go into details now, but I think it relates to the upgrading gcc. Maybe anybody knows how to fix QtCreator's autocomplete? It is really annoying thing when autocomplete stops working.
Autocompleting is done with a so-called language server. This is a program that runs alongside with your IDE and answers requests from it about what the IDE should autocomplete at any certain time. The goal of the language server then is to answer these requests efficiently, as correctly as possible and flag any other issues in the code like static analysis checks. The most popular language server nowadays, I guess, is the clangd. It's built around clang compiler but it's not tightly-coupled to it and you can use it as an language server even though you never compile your project with clang (but the sources should be at least syntactically and semantically correct to the clang, so it can provide valuable feedback for you). The problem is most likely the Qt Creator itself and should try troubleshooting the problem from the IDE side, not the compiler one.
Тема
Hy, I learn C. But I horrified by Ai. How you think, should I learn programming for finding job or better don't spend time for it. (I like write code))) .
Andrey
I have pretty old OS and environment with QtCreator 4.0, and I see no options to affect the problem directly from the IDE for now. I also don't know how to determine what the language server is used and what to do with it if I knew. But thank you, Danya, anyway. Your comment is useful.
Luca
Hi everyone. I have a question about string_view. Why it is better to pass it by value and not by reference?
klimi
Hey guys! Does anybody have experience developing for the RISC-V? I’m awaiting for this minibeast to arrive soon which has a 2.5TOPS matrix processor onboard. Good thing is Ubuntu and Fedora have RISC-V builds, gcc and clang are able to compile for this arch, and the nncase compiler supports popular DL ops, so im not starting from scratch. The goal is to implement real-time processing audio and video onboard. I’m looking for someone to share their experience and passion. Hit me in pm if you like. Have a nice day everyone😎🌞
Ya deway
Hi, I can't figure out how to send a well-formed network packet in C. My package consists of layer eth(14 byte) --> ip --> tcp --> http payload. Now I don't understand why to send this network packet I can't send it directly but rather first I have to open a connection socket (tcp) by manually entering the destination address... Isn't there a way to send the package already as is? I need to verify that the checksum calculations are correct and with the sendto() function I can't as the ip and tcp packet is crafted by the function. I tried libpcap's pcap_sendpacket() function but even with error code 0 the packet is not sent (It is not a problem of my package as I have also tried with packages obtained with wireshark so 100% well formed). Thanks for any help
Ya deway
I already done it manually, i just want inject my packet inside the network stack, like using pcap_sendpacket(handle, packet, packet_size), as u can see here i dont need open a socket, because i already have a open connection i just replace the packet recived with another
Ya deway
Well, I suggest you modify your kernel and add a system call for that. I really have no idea what you would want to do that for, you seem to want to do whacky stuff
Im trying to do the same of kali linux tool hexinject (public source), he too use the libpcap function for do that after packet manipulation, but i cant understand why when I reciving code 0, the packet is never sent.
Ludovic 'Archivist'
If you are OK with network card specific code, DPDK would work
Ya deway
Ok thanks! i will read more about it
Leovan
Hi, why we need to use typedef for value_types: template<class T> class Container { typedef T value_type; }; And can't just use smth like this: typename Container::T?
Ludovic 'Archivist'
Also, that would be Container<T>::T
Ludovic 'Archivist'
Still doesn't work tho
Anonymous
Hi, why we need to use typedef for value_types: template<class T> class Container { typedef T value_type; }; And can't just use smth like this: typename Container::T?
What if I define a template like this? template<typename U> class Container{ public: using T = double; } Should it be Container<int>::U or Container<int>::T T, U etc has meaning only during compilation stage inside template code. If the standard were to allow something like what you suggest, the parser has to be significantly more complicated and meaningless compared to what it is right now and the alternative suggestion is pretty straightforward.
Leovan
What if I define a template like this? template<typename U> class Container{ public: using T = double; } Should it be Container<int>::U or Container<int>::T T, U etc has meaning only during compilation stage inside template code. If the standard were to allow something like what you suggest, the parser has to be significantly more complicated and meaningless compared to what it is right now and the alternative suggestion is pretty straightforward.
hm, then it will be Container<int>::U, same as we need to change typedef T value_type to typedef U value_type now. And same as we need to change value_type everywhere outside template if we rename it for example to type_value. I still don't see any reason for the forbid that. Unless, as you say, the parser will be more complicated