General C++ Programming - November 2021

initializing const char array
Hi all - This isn't purely a C++ problem, but it could arise in a C++ program. I'm working on a firmware app. A library uses a struct with a const char ar...
[8 replies] Last: You're really not providing enough information to get any meaningful a... (by jlb)
Server Certificate Invalid or not present error
Using Borland C++, I need to create a small app that gets some info from a PHP file on a remote site. I have a RESTClient, RESTRequest and RESTResponse that ...
[no replies]
Difficulty renewing my Visual C++ compiler
I have had use of the Visual C++ compiler for very many years. Today for the first time after some years I needed to use it, to examine something in one of my V...
[7 replies] Last: Thanks. Revising my program for the 22 compiler has proved to be a lon... (by Anthony Appleyard)
invitation to hunt_the_wumpus refactoring
I have re-coded the console based game Hunt_the_wumpus, just for fun. There I had several considerations made about sparse use of stl libraries, at other side a...
[13 replies] Last: Attempted this myself, obviously it's heavily based on @nuderobmonkey'... (by mbozzi)
sorting and display char array
I had compile my code, it shows no error, but I cant see the correct output. I think there is something wrong with pArray and its function. //sort patient /...
[8 replies] Last: Thank you, everyone! I had solved it! (by saltyyyyy)
Compiler incompatibility
I wrote a Visual C++ program which in an .h file had the lines char*charnames ={"00", "lbutton", "rbutton", "cancel", "mbutton", ....etc.... That always compi...
[6 replies] Last: The compiler settings are set to use wide-char as default (hence the W... (by seeplus)
How to find the places of a certain character in a text?
I want to locate 0 characters in a text. For example our text is "03250150", I want it to type 0, 4 and 7 in terminal respectively. How can I do this?
[1 reply] : Use a for loop; if str == '0', print i. Tutorial on control structur... (by Ganado)
C++ vector programming help
Thanks for the help everyone, got a 100
[15 replies] Last: Please do NOT delete your question once you've gotten an answer. It m... (by MikeyBoy)
by volang
Compute a signature with private key in Server Key Exchange
On there is an example showing how to compute a signature in the section of "Server Key Exchange". (Thi...
[4 replies] Last: text files are a subset of binary files that only allow printable char... (by jonnin)
c++ array problem input and sub menus, assignment is due really soon (1,2,3)
I am a beginner of C++ and I still have no idea how to make the output like this especially question 5 to 7
[41 replies] Last: @kbw Tried to follow your advice but still cant figure out how even wh... (by s021623)
Class pointer weird ass error
Entity* entity; C2238 unexpected token(s) preceeding ';' C2413 syntax error : missing ';' before '*' C4430 missing type specifier - int assumed. Note: C++ ...
[5 replies] Last: Ohh i actually thought of that before but i didn't even try. Thanks (by Nitetesi)
DES with CBC
Hi! Does anybody know DES with CBC about? I have some code but it is very big. It Is some part of DES with CBC: //ENCRYPTION PHASE int round=16; whil...
[5 replies] Last: Off hand, DES is so insecure that triple DES (running it 3 times) is ... (by mbozzi)
C++ 20 Pointer Declaration
GCC Still generating error messages despite the synate is correct for the pointer declaration: #include <iostream> using namespace std; int main() { i...
[19 replies] Last: The definitive answer is in the language grammar: (by mbozzi)
Ray sphere intersection
I would need to create a ray sphere intersection in C++. Kindly help me with creating a sphere first then do a ray sphere intersection.
[1 reply] : Sruthi04 (1) I would need to create a ray sphere intersection in C++.... (by jonnin)
I need help with the last part of my code: this is the output I need but im not sure where to start dynamic (uses: p_natural, Number("one"), Number("two...
[4 replies] Last: thank you for those links I figured it out now (by ocKiNOsIi)
tax calculation float functions c ++
m a beginner programmer and I was to ask a program which calculates income tax based on a salary. Then to change the code and create below functions however I h...
[1 reply] : > create below functions however I have no idea how to create them her... (by ne555)
Ascending Order
I have created this program that creates a random array of 20 numbers and then shuffles them. The next thing I would like to implement is to be able to reprint ...
[4 replies] Last: Possibly: #include <iostream> #include <algorithm> #include <random... (by seeplus)
by SSyvOO
Fahrenheit To Celsius
You are to write a program that converts a Fahrenheit temperature to Celsius. The design of this program is important as I want you to break your program into s...
[3 replies] Last: Please use code tags when posting code. See (by keskiverto)
A grade calculator. Everything works fine EXCEPT it does NOT display all the courses and grades average is off.
#include <iostream> #include<iomanip> using namespace std; int numStudents2; int main() { char letter; cout <<"Welcome to Jessie's Academy Grad...
[3 replies] Last: You need 2d arrays to store the subject names/scores for all the stude... (by seeplus)
How else-if and else executing at same time
Here is the program Our teacher discussed in Class. #include <stdio.h> #include <unistd.h> #include <sys/types.h> #include <sys/wait.h> int main(void) { ...
[3 replies] Last: ok. I suspected as much, but as I said, fork() is a distant memory t... (by jonnin)
November 2021 Pages: 123... 6
  Archived months: [oct2021] [dec2021]

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