Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Language IDEs » C / C++ IDE (CDT) » File won't run
File won't run [message #874518] Mon, 21 May 2012 04:34 Go to next message
andrew gu is currently offline andrew guFriend
Messages: 1
Registered: May 2012
Junior Member
Hi guys,
So I'm writing a C program that requires user input, except for some reason everytime I try to run the program, nothing appears in the console screen. So I try some other program that requires no user input, and that works out fine. I try to run the program via command line, and that works fine. Any ideas?

code:
#include <stdio.h>

int main(void)
{
float original_amount, amount_with_tax;

printf("Enter an amount: ");
scanf("%f", &original_amount);
amount_with_tax = original_amount * 1.05f;
printf("With tax added: $%.2f\n", amount_with_tax);

return 0;
}
Re: File won't run [message #874594 is a reply to message #874518] Mon, 21 May 2012 07:55 Go to previous message
Axel Mueller is currently offline Axel MuellerFriend
Messages: 1973
Registered: July 2009
Senior Member
See http://wiki.eclipse.org/CDT/User/FAQ#Eclipse_console_does_not_show_output_on_Windows

Before you ask
- search this forum
- see the FAQ http://wiki.eclipse.org/CDT/User/FAQ
- google
Previous Topic:Paste Corrupts Code?
Next Topic:Selection of Language Extension
Goto Forum:
  


Current Time: Thu Mar 28 18:54:42 GMT 2024

Powered by FUDForum. Page generated in 0.02870 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top