Click here to Skip to main content
15,891,136 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: send continuos data to an edit control for display Pin
krmed22-Jan-08 7:13
krmed22-Jan-08 7:13 
GeneralRe: send continuos data to an edit control for display Pin
Wes Aday22-Jan-08 4:31
professionalWes Aday22-Jan-08 4:31 
GeneralRe: send continuos data to an edit control for display Pin
LCI22-Jan-08 4:57
LCI22-Jan-08 4:57 
GeneralRe: send continuos data to an edit control for display [modified] Pin
Cedric Moonen22-Jan-08 4:35
Cedric Moonen22-Jan-08 4:35 
Questionhow to calculate any amont minimum? Pin
gentleguy22-Jan-08 2:54
gentleguy22-Jan-08 2:54 
AnswerRe: how to calculate any amont minimum? Pin
Maximilien22-Jan-08 2:58
Maximilien22-Jan-08 2:58 
AnswerRe: how to calculate any amont minimum? Pin
CPallini22-Jan-08 3:01
mveCPallini22-Jan-08 3:01 
AnswerRe: how to calculate any amont minimum? Pin
David Crow22-Jan-08 4:10
David Crow22-Jan-08 4:10 
li zhiyuan wrote:
how can i define a...way to calculate such miminum?


Put your numbers in a text file of some sort (e.g., num.dat). Create a console application using:

void main( void )
{
    int nNumber,
        nMin = INT_MAX;
 
    while (fscanf(stdin, "%d", &nNumber) != EOF)
    {
        if (nNumber < nMin)
            nMin = nNumber;
    }
 
    printf("Min = %d\n", nMin);
}
And then type one of the following at a command prompt:

type num.dat | prog.exe
prog.exe < num.dat


"Normal is getting dressed in clothes that you buy for work and driving through traffic in a car that you are still paying for, in order to get to the job you need to pay for the clothes and the car and the house you leave vacant all day so you can afford to live in it." - Ellen Goodman

"To have a respect for ourselves guides our morals; to have deference for others governs our manners." - Laurence Sterne


JokeRe: how to calculate any amont minimum? Pin
CPallini22-Jan-08 4:29
mveCPallini22-Jan-08 4:29 
Generalin fo needed on Gradient fill Pin
sarat22-Jan-08 1:53
sarat22-Jan-08 1:53 
QuestionRe: in fo needed on Gradient fill Pin
CPallini22-Jan-08 2:14
mveCPallini22-Jan-08 2:14 
GeneralRe: in fo needed on Gradient fill Pin
sarat22-Jan-08 4:04
sarat22-Jan-08 4:04 
GeneralRe: in fo needed on Gradient fill Pin
sarat22-Jan-08 18:56
sarat22-Jan-08 18:56 
GeneralRe: in fo needed on Gradient fill Pin
sarat22-Jan-08 20:38
sarat22-Jan-08 20:38 
GeneralTypedef nightmare! [modified] Pin
Lea Hayes22-Jan-08 1:47
Lea Hayes22-Jan-08 1:47 
QuestionRe: Typedef nightmare! Pin
CPallini22-Jan-08 2:04
mveCPallini22-Jan-08 2:04 
GeneralRe: Typedef nightmare! Pin
Lea Hayes22-Jan-08 2:28
Lea Hayes22-Jan-08 2:28 
GeneralRe: Typedef nightmare! Pin
CPallini22-Jan-08 2:38
mveCPallini22-Jan-08 2:38 
GeneralRe: Typedef nightmare! Pin
Lea Hayes22-Jan-08 3:02
Lea Hayes22-Jan-08 3:02 
QuestionRe: Typedef nightmare! Pin
CPallini22-Jan-08 3:21
mveCPallini22-Jan-08 3:21 
GeneralRe: Typedef nightmare! Pin
Lea Hayes22-Jan-08 3:28
Lea Hayes22-Jan-08 3:28 
GeneralRe: Typedef nightmare! Pin
Luc Pattyn22-Jan-08 2:12
sitebuilderLuc Pattyn22-Jan-08 2:12 
GeneralRe: Typedef nightmare! Pin
Lea Hayes22-Jan-08 2:17
Lea Hayes22-Jan-08 2:17 
GeneralRe: Typedef nightmare! Pin
CPallini22-Jan-08 2:18
mveCPallini22-Jan-08 2:18 
GeneralRead Data from Serial Port Pin
Susanmat22-Jan-08 1:28
Susanmat22-Jan-08 1:28 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.