Beginners - June 2019 (Page 6)

by sturk
C++ compilation issue
 
Hi, I am receiving 2 kinds of errors from my compiler as shown below. One is for the 'random' that is redeclared and another is for operator-. Can anyone show m...
[10 replies] Last: I just copied your code and added template overload and included heade... (by malibor)
Lowest common ancestor in a root tree.
 
Hello guys! I'm having an issue understanding how to exactly approach the following problem: Rooted tree is given on the standard input as a List of paren...
[3 replies] Last: From the input data we can trace the ancestry for each node: 6 ->5->3... (by keskiverto)
Sorting a matrix
 
How to sort a matrix as in 4x4 like 4 4 6 1 1 2 7 2 9 4 7 3 1 5 7 2 9 3 with the following rules : A = A(1),A(2),...,A(n) B = B(1),B(2),...,B(n) for 2 rows...
[10 replies] Last: Please explain the nuts . (by keskiverto)
Class Template Specialization
 
Hi! I'm building header-only statistics library that uses a lot of templates. I have created a class template that takes as input an array-like container: ...
[8 replies] Last: If you wan't your class to accept 2 kinds of construction parameters s... (by malibor)
Pass an array address between applications
 
Hi, Firstly I would like to point out that I am new to C++. I am writing an expert advisor and indicator in MQL4 and a DLL in C++. The DLL will handle th...
[4 replies] Last: I have found a satisfactory way of solving my problem in MQL by using ... (by skiner36)
Help
 
I
[3 replies] Last: #include <bits/stdc++.h> #define ll long long using namespace std; in... (by cc046)
Sorting arrays next to other arrays which are the same
 
I just wrote a program where program sorts people by time(minutes).But what and where should I add a code, if minutes are the same and I need to sort seconds as...
[1 reply] : bool comp(const people &p1, const people &p2) { return p1.min ==... (by dutch)
Resetting game
 
I am trying to reset the game until the user puts in the correct name. How do I do that? I am trying to figure out how to reset the code back to the sta...
[3 replies] Last: Nvm I just relized I dont have the code allowing for the user to reent... (by Emoangel1478)
sorting array and matching other array and getting error
 
I'm trying to write a program where I write information of people like: name,minutes and seconds.I need to sort people by the time. I can't understand how to so...
[2 replies] Last: First, this: struct people z ; No no no. That looks like C code. Th... (by Repeater)
Advice for future learning
 
Hello guys.I am finishing my second term at university and I hope to get some advice for the future.I want to learn something besides what I have learned at uni...
[3 replies] Last: To be honest, @Zivojin, if you've finished your second term (semester?... (by lastchance)
by sturk
C++ warning of narrowing conversion
 
Hi, why does the compiler prompt me of this warning and how do I resolve this? Stressing me out. And thing is, I can't modify the main() permanently, so I can't...
[8 replies] Last: Thanks Keskiverto. So it looks like the OP can solve the problem by t... (by dhayden)
by Bopaki
Help with copy constructor & assignment Operator (1,2)
 
When I run this code I get these errors: allocation error: allocation error: allocation error: allocation error: allocation error: allocation error: ...
[20 replies] Last: Thank all for your assistance (by Bopaki)
initializers before for error
 
Hello everybody! Our teacher asked us to write a program for a bank.[yes its a homework , but i already have written it all] in this program we have to get so...
[4 replies] Last: The error codes are very easy to read in this case. LOTS of lines wit... (by zapshe)
char array through function
 
I have been busy in trying to pass 2d array through function but no break through can any one point out the issue as i am in dire need of help int main() {...
[1 reply] : #include <iostream> using namespace std; const int length =100; voi... (by lastchance)
Super confused plz help
 
Sorry for not being clear in my question. My problem is I am trying to make an amortization table which would depending on the input of the user will display t...
[9 replies] Last: Hello jumbee2, I started to ask this until I got into something else ... (by Handy Andy)
+ operator
 
The error is in line 80 with + operator. I don't understand why. #include<iostream> #include<cstdlib> #include<ctime> #include<vector> #include<stri...
[3 replies] Last: c and p are not strings; they are stringstreams. // string l... (by JLBorges)
Arrays and Queueing
 
Having a problem with my code. When I type in a certain size of names I want to be enqueue it shows more names from the txt file than it should. I think I hap...
[5 replies] Last: IDEs designed for large projects only recompile when they detect a cha... (by jonnin)
help-INTRPATH
 
Can anybody please explain the given testcase? And how to find out if two path contains only one vertex? Please help guyz. I have literally no idea about thi...
[9 replies] Last: @dutch, idk if you are still reading this forum, you deleted the above... (by kanken)
Help (1,2,3)
 
Given two natural numbers N and K where N >= 2, you have a list of available numbers as all numbers in inclusive range K to K+N-1. You can sum any two natural n...
[56 replies] Last: https://www.geeksforgeeks.org/how-to-compute-mod-of-a-big-number/ (by abo)
by lame
help plz (1,2,3)
 
We have been given an array of size n , and two integers k and x; Now, We can perform the following operation any number of times (including zero): 1.Pick ex...
[47 replies] Last: For all those facing problem in mod,here is the link https://www.geek... (by abo)
June 2019 Pages: 1... 45678... 13
  Archived months: [may2019] [jul2019]

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