How i take a full expration from user as input in c++ programme like (2+7 or 7*8 )

You take it in as a string and then parse it into its constituent parts and interpret it.

std::string expression

std::getline(cin, expression);

// Parse string here
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.