Показать сообщение отдельно

  #5  
Старый 11.01.2009, 19:59
4p3
Участник форума
Регистрация: 18.08.2008
Сообщений: 159
С нами: 9332069

Репутация: 92
По умолчанию

Цитата:
Сообщение от ankden  
Люди, кто может решить эту задачу без использования массива помогите пожалуйста
PHP код:
//---------------------------------------------------------------------------
#include <iostream>
#include <cstdlib>
#pragma hdrstop
using std::cout;
using std::cin;
using std::endl;
using std::system;
//---------------------------------------------------------------------------
typedef unsigned char uchar;
#pragma argsused
int main(int argccharargv[])
{
        
uchar firstsecondthird;
        
int n 0;
        do
        {
                
cout << "enter three digits: ";
                
cin  >> first >> second >> third;
                if (
first second && second third)
                {
                        
cout << "Correct input. Here is digits: ";
                        
cout << first << ":"   << second
                             
<< ":"   << third << endl;
                }
                else
                {
                        
cout << "They are not sorted" << endl;
                }
                
n++;
        } while (
9);
        
system("pause");
        return 
0;
}
//--------------------------------------------------------------------------- 
 
Ответить с цитированием