Ask Question
4 October, 02:29

Write a few statements that open a file called "greeting", write the message "hey!" to the file - - and then close it. declare any variables needed.

+4
Answers (1)
  1. 4 October, 06:14
    0
    C++:

    int main () {

    std::ofstream output {"greeting. txt"};

    output << "hey!";

    output. close ();

    return 0;

    }
Know the Answer?
Not Sure About the Answer?
Find an answer to your question ✅ “Write a few statements that open a file called "greeting", write the message "hey!" to the file - - and then close it. declare any ...” in 📘 Computers and Technology if you're in doubt about the correctness of the answers or there's no answer, then try to use the smart search and find answers to the similar questions.
Search for Other Answers