c++ check first character of string

#include <iostream>
#include <string>

int main() {
    std::string inputString;

    // Input: Read a string from the user
    std::cout << "Enter a string: ";
    std::getline(std::cin, inputString);

    // Check if the string is not empty
    if (!inputString.empty()) {

        // Access the first character of the string
        char firstCharacter = inputString[0];

        // Display the first character
        std::cout << "First character of the string: " << firstCharacter << std::endl;

        // Check if the first character is a letter
        if (std::isalpha(firstCharacter)) {
            std::cout << "The first character is a letter." << std::endl;

            // Check if the first character is an uppercase letter
            if (std::isupper(firstCharacter)) {
                std::cout << "The first character is an uppercase letter." << std::endl;
            } else {
                std::cout << "The first character is a lowercase letter." << std::endl;
            }
        } else {
            std::cout << "The first character is not a letter." << std::endl;
        }
    } else {
        std::cout << "The string is empty." << std::endl;
    }

    return 0;
}