Page 1 of 1

Codelite-terminal

Posted: Sun Apr 30, 2023 7:20 pm
by javimatia

Good afternoon, I am starting with codelite and when executing the code that I attached, the codelite terminal fails and does not react, I mean, it asks you for the numbers, I type 23 for example, I press enter, I type 56 and it returns 23 6. In other cases it stays waiting and no matter how much I press enter it does nothing.
If in settings I choose gnome terminal, it works correctly.
It also works fine if I run it from the OS terminal.
So I wanted to know if I have something misconfigured or if it is a system or codelite terminal error.

Thank you so much.

Code: Select all

#include <iostream>
using namespace std;

int main() {
	int a, b;
	cout << "escribe dos numeros: ";
	cin >> a >> b;
	cout << endl << a << " " << b;
}

Re: Codelite-terminal

Posted: Sun Apr 30, 2023 8:43 pm
by DavidGH

Hi,

What happens if you add another 'endl' to the end of the line?

Code: Select all

cout << endl << a << " " << b << endl;

Regards,

David


Re: Codelite-terminal

Posted: Sun Apr 30, 2023 9:26 pm
by javimatia
DavidGH wrote: Sun Apr 30, 2023 8:43 pm

Hi,

What happens if you add another 'endl' to the end of the line?

Code: Select all

cout << endl << a << " " << b << endl;

Regards,

David

cout << a << " " << b; or cout << endl << a << " " << b << endl;

just same problem, only fails on codelite-terminal