Answer the question
In order to leave comments, you need to log in
Why is the string output in the wrong encoding?
There is a file "questions.txt". File content:
When do you have to make a block diagram of the program?
Which program provides translation of programs with high-level language into the language of a lower level?
The algorithm , in which the actions are performed one after the other , without repeating is called:
For the squaring function is used
:
...
bool readQuestions(string address,string* qPointer)//считывает вопросы с файла по полученному адресу и записывает их в строки указателя
{
ifstream fQuestions(address);
if(!fQuestions)//проверка на наличие файла
{
printf("Error: file '%s' not found!\n\n",address);
return false;
}
for(int i =0; i< 15; i++, qPointer++)//15 вопросов
{
getline(fQuestions,*qPointer);//считывание и запись строки
}
return true;
}
string question[15];//тексты вопросов
readQuestions("questions.txt",question);
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question