Questions tagged as 'c++'

2
answers

How to check and print values that are repeated in a vector

I have the following problem to check the vectors that are repeated in a Vector: Given a sequence of n real numbers, determine the numbers that make up the sequence and the number of times each occur in it. Example: n = 8 Sequence:...
asked by 18.08.2017 / 17:25
0
answers

Game of life c ++

Hello! I'm developing the game of life and I'm not getting the rules applied correctly (I do not know if it's because of the function it prints or the function that checks the rules). For those who do not know, I'll tell you a bit about the game...
asked by 08.09.2017 / 20:49
2
answers

Problems converting integer to string (stringstream) c ++

#include <iostream> #include <string.h> #include <sstream> using namespace std; int main(int argc, char *argv[]){ int n, aux; string hexa=""; stringstream hexa_aux; cin >> n; while(n != 0){ a...
asked by 10.08.2017 / 02:13
1
answer

How to pass structures to template class functions

I just do not understand why you're wrong. This code works. template class test{ public: struct st1{ T a, b, c; }; struct st2{ T d, e, f; }; T foo1(st1 *st); st1 *foo2(); }; template typename test::st...
asked by 24.08.2017 / 21:35
1
answer

Compare Plugin NotePad ++ is it possible to use in VB6 or .NET?

I need to know if it is possible to use the Notepad ++ Compare plugin in the projects made in VB6 and .NET. If so, I would like some tips on how I can use it. And I have no idea how to start. The system that I'm adjusting needs to send me...
asked by 11.08.2017 / 19:24
0
answers

Data input string and double

I'm in a project implementing a C ++ calculator that uses variables. So, if I define a variable x = 5, and I type x ^ 2 then it returns the value of 25. For this, I have to store the variable name and the corresponding value. The user would type...
asked by 12.08.2017 / 15:22
1
answer

What is the difference between GetKeyState () and GetAsyncKeyState ()?

I have always used GetKeyState() to know if the user is pressing a key, but I see that many people use GetAsyncKeyState() more. With this I got the following doubts: What's the difference between the 2? When should I use e...
asked by 15.08.2017 / 22:32
1
answer

INTERNAL COMPILER ERROR Visual Studio 2017 with SFML

I'm having a problem compiling a code in visual studio 2017 with the SFML libraries, when I try to compile it it gives the following error:   INTERNET COMPILER ERROR in 'C: \ Program Files (x86) \ Microsoft Visual Studio \ 2017 \ Community \...
asked by 26.07.2017 / 17:42
2
answers

Is it possible to view all the contents of a namespace in C ++?

When you make the policy: using namespace std; //primeira forma You get direct access to all elements of the std namespace. But suppose you want to use only std::cout or std::endl so it would be better to use the policy: u...
asked by 15.07.2017 / 19:17
1
answer

Optimizing codes with VC ++ and NASM / MASM

Good evening. I often use NASM in VC ++ on x86 and am learning how to use MASM in x64. Is there any way to specify where each argument goes and the return of an assembly function in such a way that the compiler manages to leave the data there...
asked by 12.07.2017 / 03:18