Beginners (Page 2)

Review / Advice (1,2)
 
Hello everyone. Im a freshman in college taking my first programming class. It teaches c++. One of o...
[26 replies] Last: One cool aspect of the {fmt} library, as well as C++20's <format>, is ... (by George P)
Question about the move contructor
 
Here is my code, I got instance a, and b created by Move constructor base on a. Class Move has one...
[1 reply] : The issue is in main(). &(a.data), &(b.data) is the address of the .da... (by seeplus)
class to aggregate and evaluate many functions in batch
 
I am trying implement a class which should be able to store several functions, like int p1(int x) ...
[7 replies] Last: I figured a working example might help. But you're right, it's essenti... (by mbozzi)
'include <cassert>
 
It the header file #include <cassert> still valid in modern c++? I know TDD users assert, but thi...
[6 replies] Last: [quote=Peter87]I guess contracts would have been an alternative. We al... (by George P)
Eigen matrix vs for loop matrix give off results
 
Why is that if I print my matrix inside the for loop gives different results that when I print it ou...
[7 replies] Last: dv(j + (ny + 1)*i) oh yeah this is it, I have completely missed this... (by JamieAl)
Need help :)
 
Hey guys good evening. So i've been stuck on this for a bit. The exercise asks me to get 2 answ...
[11 replies] Last: Code intent should always be clear. What intent can you derive from t... (by George P)
Character Array & Pointer - Confused
 
int main() { char arr = {'F', 'C'}; std::cout << arr+0 << std::endl; // FC std::cout...
[3 replies] Last: [quote=salem c]To see the pointer value, you have to cast it to some o... (by Peter87)
How can i change this [Try Catch] C++ code?
 
Hello all im new to this forum and im a C++ beginner too so please forgive me if i did something w...
[4 replies] Last: Yea that is exactly what i wanted...Thank you soo much sir i rly appre... (by TharinduCplusPlus)
Optimizing finding the largest element in an array
 
I have written some code that executes fine, but I am looking to further optimize the code with any ...
[6 replies] Last: well, you learned something in the class as well. The trick is getting... (by jonnin)
by Rendo
Difficulty understanding for loop iteration results (1,2)
 
Hi, I am extremely new to C++, I apologise in advance if my question is long winded or difficult to ...
[25 replies] Last: I can't see myself using some sort of object for a local 2 element ar... (by seeplus)
Trying to print one digit at a time using a specific algorithm
 
Im trying to print on digit at a time for example, 123 would be 1 2 3 using an algorithim my ...
[7 replies] Last: Here is the link for the algorithm OMG - what are they teaching the... (by seeplus)
bug around while(!())
 
there is this bug around while(!()) where i have to re enter my year because it didnt register ...
[9 replies] Last: Playing around: #include <iostream> #include <string> #include <typ... (by seeplus)
No suitable constructor exists to convert from 'int' to 'Uint64' (user-defined type)
 
I can't compile parts of the SDL 1.2 (here ) with the Visual C++ compiler. In particular, this part...
[8 replies] Last: The error messages indeed suggest that Uint64 is being defined as a st... (by Peter87)
by Pen72
Minimal cycle size in graph
 
I got five passed cases and five wrong test cases with the code below, thanks for the help in advanc...
[6 replies] Last: Yes it works, thank you so much, and thanks for your explanation. (by Pen72)
Eliminating use of for loop with Eigen
 
I am trying to build a row vector and column vector using Eigen library to multiply them together to...
[1 reply] : See: https://eigen.tuxfamily.org/dox-devel/group__TutorialSTL.html (by JLBorges)
Extract rows/columns of matrices in C++ vs MATLAV
 
In MATLAB you can extract the first and last rows of a matrix by A(1,:); A(N,:); Is the...
[18 replies] Last: Thanks everyone for the incredible feedback/info! I am working with Ei... (by JamieAl)
iterator problem
 
I am copying an example from a book and it wont compile. I am trying to copy a vector<string> to a ...
[4 replies] Last: Just been looking at it and I noticed the return type. Thanx for look... (by mickydint)
by sarvcr
Linked List with templates
 
Question Solved. Look at SeePlus comment if you have a problem like this. Hi! Long story short, ...
[9 replies] Last: It's working perfectly now. I really appreciate all the help you've gi... (by sarvcr)
char*/string function type
 
Hi folks! I'm trying to write DLL with a function that accepts a string, manipulates it and retur...
[4 replies] Last: @thmm Thank you, I used your code and it works now! You are awesome! ... (by Al Green)
I dont understand a textbook question
 
I am learning C++ with the help of a book called C++ Crash Course by Josh Lospinoso. Chapter 3 is ab...
[10 replies] Last: @afduggirala, fair warning, there is currently only one compiler capab... (by George P)
Pages: 1234... 11
  Archived months: [apr2022]

Cannot post in this page. To post a new message, go to the first page.