[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[h-e-w] printf order in emacs shells
From: |
Sayth Renshaw |
Subject: |
[h-e-w] printf order in emacs shells |
Date: |
Mon, 27 Jun 2011 16:29:42 +1000 |
On windows is there anyway to make the emacs shell behave correctly with printf.
I have used eshell, shell, cmd, and powershell. None of them gets the
behaviour right. If I use the windows dos command prompt then
everything works as expected. For example.
This basic c script.
# include <stdio.h>
int main()
{
float a,b,c,interest;
printf("Type in amount in dollars cents:\n");
scanf("%f",&a);
b = 0.075;
c = a * b;
interest = a + c;
printf("The total including interest is $%.2f", interest);
return 0;
}
The printf follows the action incorrectly instead of printing to the
screen and awaiting input.
c:\MyC>sum.exe
sum.exe
22
Type in amount in dollars cents:
The total including interest is $23.65
c:\MyC>
Is there anyway to fix this behaviour?
- [h-e-w] printf order in emacs shells,
Sayth Renshaw <=