πŸ“Š C++
Q. What is the output of this program?
Code:
#include 
    using namespace std;
    int main()
    {
        enum channel {hotstar, zeetv, max};
        enum symbol {anamol, hotstar};
        int k = 0;
        for (k = hotstar; k <= zeetv; k++) {
           cout << k;
        }
        return 0;
    }
  • (A) Compilation Error
  • (B) Runtime Error
  • (C) Garbage Value
  • (D) hotstar
πŸ’¬ Discuss
βœ… Correct Answer: (A) Compilation Error

You must be Logged in to update hint/solution

πŸ’¬ Discussion


πŸ“Š Question Analytics

πŸ‘οΈ
192
Total Visits
πŸ“½οΈ
4 y ago
Published
πŸŽ–οΈ
Rohan Raj
Publisher
πŸ“ˆ
86%
Success Rate