Beginners - November 2020 (Page 8)

compute numberOfseconds of week to date and week to month
 
I am trying to find out totalseconds in week to current datetime auto tp = floor<seconds>(system_clock::now()); auto dp = floor<days>(tp); dp -= we...
[1 reply] : http://sscce.org/ Post the minimal main() and include files necessary... (by salem c)
Sentinel didn't working
 
Hello, I use the sentinel to control the loops to find the smallest n numbers. However, after I run it, the loops keep running even though I input the Sentinel ...
[7 replies] Last: wait, I can get the answer correctly now, hahahaha btw thank you for h... (by Violetzz)
convert array numbers from binary to octal
 
hi, ive asked this before and i know how to convert it now, thanks to the people that helped, but is there a way i can to it without using 'string', 't.length ;...
[6 replies] Last: @seeplus thank you sooo much!!:) (by laura fidarova)
by jonnin
RLE Alogrithm with Integers
 
why do you need a != 0 when a is forced between 10 and 20? what was that put in to accomplish? I have no idea how your code is trying to solve the problem. g...
[2 replies] Last: I am saying I don't think your logic is correct. your code counts al... (by jonnin)
inOrder Predecessor given node
 
I have a Binary Tree and I want to find the inOrderPredecessor given the node. I'm aware it would be easier using the root, but I'm testing out other methods. ...
[1 reply] : You're pretty close. BTNode* inOrderPredecessor(BTNode* node) { ... (by dutch)
adding array variables columns and rows
 
is there a better way(more efficient) of doing this? #include <iostream> int addition3x3(int array ); int additionrows(int array ); int additioncolumns(int...
[3 replies] Last: Thank you very much for your answer, dutch. I didn't reply sooner beca... (by closed account o35DwA7f)
Why cant I cout or ofstream my string arrays value
 
Write your question here. What's wrong I am supposed to take 4 integers from data.txt which are 1 2 3 3 and cout or ofstream the highest values for example ...
[14 replies] Last: Exactly (by Carabus)
please proofread the code to avoid memory leak
 
can you just check if 'delete' is in the right place, please. i'm afraid of doind it wrong and having troubles after #include <iostream> #include <ctime> ...
[4 replies] Last: thank you all so much, i'll be taking notes!:) (by laura fidarova)
Why does character input display a complete string if a string is entered?
 
Here's a simple code #include <iostream> using namespace std; int main() { char c; cin >> c; cout << c; return 0; } If I enter, "...
[5 replies] Last: Also, how do I check if the user has entered a single character or mo... (by seeplus)
by yvez
Do-while loop displays 2 prompt at a time, please reply
 
Hello, I'm new to programming and trying a program that You need to guess the name of a video game character, there are only 3 guesses if you ran out of guesses...
[7 replies] Last: different styles... I prefer using std::cout; and similar. I find st... (by jonnin)
dynamic cast?
 
Hi I am trying to learn what dynamic cast is, and everything i read just leaves me more confused than I was. Hoping someone could explain it in easy terms. What...
[10 replies] Last: @Repeater, that is both hilarious and sad. I've had to use reinterpr... (by deleted account xyzzy)
Data structures
 
Hello. I have a new question. So we have a task to simulate elevators in a building. We have 2 elevators, the two of them have different capacity. When an eleva...
[2 replies] Last: Post a sample input file, preferably with expected output. (by dutch)
Pass by reference/Pass by value/Parameters/Functions
 
I cannot figure out how to use parameters with functions. In the code, I have a functions for getting data, displaying a menu, processing the menu choice, and t...
[5 replies] Last: Hello runningbear, When I tried to compile the program there was some... (by Handy Andy)
class errror c++
 
I am getting an error in vs c++ compilor showing no match for << operator error in c++, followed by lots of unknown errors,,, Here's the code : #include<io...
[6 replies] Last: Default declaring Distsign 's sign data member to be private is g... (by deleted account xyzzy)
Code for search exam result by Name, Roll No., DOB, Mob. No
 
Well if you explained in more detail what you would like, the format of the file/data you're trying to search and posting your existing code............
[no replies]
Phonebook multidimensional array from file?
 
Honestly I think I'm having a huge brainfart because I swear I've done this before but cannot think of how I did it. My goal right now is to put a list of infor...
[4 replies] Last: If you need to use a 2d string array, then consider: #include <fstr... (by seeplus)
by Mif
Can a dll use another dll ?
 
Hello again.. I have write few dlls for my code.. and now what remains from my entire code is the main.c, menus.c, resource.h and resource.rc So my ques...
[5 replies] Last: Okay I got it.. I have to link as I do with a normal .c file. In fac... (by Mif)
help with code (adding if else...)
 
I am in a beginner programming class for C++, I am working on my final project we have been building on this semester. I am having some trouble fixing some thin...
[6 replies] Last: srand() is usually placed at the beginning of main() and executed only... (by seeplus)
Check my code, please!
 
I wrote the code but it doesn't work properly. Please check and correct mistakes or suggest your solutions. I will be grateful! I also add a task A two-dimen...
[5 replies] Last: #include <random> #include <iostream> #include <algorithm> #include ... (by seeplus)
Where is the Segmentation Fault?
 
SO I've been writing a custom string class for school, and I've been getting a couple of segmentation faults, and I'm having trouble finding where they are. ...
[13 replies] Last: I've got a segfault at line 372 That's expected - as you're using c... (by seeplus)
November 2020 Pages: 1... 678910... 14
  Archived months: [oct2020] [dec2020]

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