Check if a Char Array is equal to a string in C++
This tutorial will discuss about unique ways to check if a char array is equal to a string. Table Of Contents Technique 1: Using strcmp() Technique 2: Using string::compare() function Summary Technique 1: Using strcmp() The strcmp() function accepts two strings (char pointers) as arguments, and returns 0 if both the strings are equal. We […]
Check if a Char Array is equal to a string in C++ Read More »