Beginners - August 2022 (Page 3)

Book Cipher C++
 
Hi, I have read two previous posts on this forum about coding a Book Cipher in C++. I am very very new to C++ and have a lot of trouble trying to figure out a f...
[13 replies] Last: Yes, thank you have been so much help! You are the best!!! (by d3sousa92)
C++ function array
 
C++, how do I add function where it can find the mean/med of an array? Please check my code, it gives me wrong output in the median function. #include<...
[3 replies] Last: You don't say what you are being asked to do. However, the class name ... (by seeplus)
Dynamic allocation and functions
 
Consider the sippet below: char *func(void) { char *str = new char ; str = 'a'; str = 'b'; str = '\0'; return str; } int main() { ...
[16 replies] Last: Thank you all for contributing to this topic, I learn so much from you... (by ninja01)
New to learn Cpp
 
Hello everyone i am in the First Year of my engineering and new to learn Cpp Programming language, can anyone please suggest me the best books/tutorials and als...
[8 replies] Last: My first book was a Sam's Teach Yourself & I love that book. The previ... (by CodeChaser)
The worst case of quicksort
 
I have searched online about when will the worst case of quicksort happen, but there are many results like: 1. When the pivot is picked randomly. 2. When the p...
[6 replies] Last: Thanks everyone for the detailed explanation ! (by IHaveSmallBrain)
I don't know why this isn't working?
 
Write your question here. #include <iostream> #include <string> using namespace std; // Write performOperation() function declaration here double ...
[6 replies] Last: if (op == "/") return numberTwo ? numberOne / numberTwo : !(std::c... (by seeplus)
I don't understand recursion in binary search tree
 
I have program that print the nodes of a BST in inOrder() traversal. void inOrder(Node* root) { if (root != nullptr) { inOrder(root->left);...
[6 replies] Last: Thanks everyone ! (by IHaveSmallBrain)
Program terminating after std::out_of_range while trying to find EOF
 
Howdy yall, I am trying to count the number of rows in a .csv file however I have repeatedly run into a problem while running it where it will work until the 2...
[8 replies] Last: However, I think the logic is not right for reading the csv file. I th... (by seeplus)
Binary Combination of a given N
 
Hello everyone, I need a small help. I need to store binary combination of a given a positive integer number N in a vector. Say N=2, so I need to obtain first...
[10 replies] Last: using u32 = std::uint32_t; u32 constexpr avail_mask = 0b0001111; // ... (by mbozzi)
C++ class declaration
 
I often gets confused on this as I am reading some of the libraries that I am using in my code and how they are being used. Some classes are declared like Opti...
[8 replies] Last: x = y; x is on the left, in english, its the Left Hand Side (lhs) y is... (by jonnin)
by Tima11
I get many errors when including stb_image.h
 
Hello, I am working with stb library. This is my texture.cpp file: #define STB_IMAGE_IMPLEMENTATION #include "stb_image.h" class Texture { public: const c...
[2 replies] Last: Oh, it worked. Thanks! (by Tima11)
Read from ofstream output
 
Hello everyone, I'm a student of civil engineering in the middle of creating a topology optimization algorithm using C++. My only experience with coding was Ma...
[12 replies] Last: Hello again everyone, I'm overwhelmed with all the replies I got. This... (by Sreiner)
visual studios openning code
 
Write your question here. I am starting a class using visual studios for c++ in windows desktop controls. I did the initial Hello World that all courses start w...
[6 replies] Last: Gee, Geckoo, I did mention there are no guarantees the code would work... (by George P)
template, files problem
 
I have 4 files: header.h, header.cpp, header2.h and header2.cpp, like the ones below: header.h # pragma once # include "header2.h" template<class T> class f...
[7 replies] Last: Avoid circular dependency by all means! If class Bar (declared in... (by kigar64551)
I need help
 
Hi there!. I am learning more programming skills. To be honest I already know how to do them, but my emotional skill to sit down and program them is zilch. I ne...
[5 replies] Last: Class and struct are almost identical, the only difference in c++ is p... (by jonnin)
August 2022 Pages: 123
  Archived months: [jul2022] [sep2022]

This is an archived page. To post a new message, go to the current page.