Search
 
SCRIPT & CODE EXAMPLE
 

CPP

use of alphanumeric function c++, check if alphabet or digit from string

// Program to illustrate iswalnum() function
#include <cwctype>
#include <iostream>
using namespace std;
  
int main()
{
  
    wchar_t ch1 = '?';
    wchar_t ch2 = 'g';
  
    // Function to check if the character
    // is alphanumeric or not
    if (iswalnum(ch1))
        wcout << ch1 << " is alphanumeric ";
    else
        wcout << ch1 << " is not alphanumeric ";
    wcout << endl;
  
    if (iswalnum(ch2))
        wcout << ch2 << " is alphanumeric ";
    else
        wcout << ch2 << " is not alphanumeric ";
  
    return 0;
}
Comment

PREVIOUS NEXT
Code Example
Cpp :: C++ Infinite while loop 
Cpp :: quicksort geeksforgeeks 
Cpp :: c++ float and double 
Cpp :: define in cpp 
Cpp :: all permutations with repetition C++ 
Cpp :: set width qpushbutton 
Cpp :: linked list in c++ 
Cpp :: cpp define 
Cpp :: cpp map insert 
Cpp :: doubly linked list code in c++ 
Cpp :: c++ class template 
Cpp :: passing structure to function in c++ example 
Cpp :: how to replace part of string with new string c++ 
Cpp :: how to initialize a queue in c 
Cpp :: c++ read matttrix from text file 
Cpp :: stl in c++ 
Cpp :: toString method in c++ using sstream 
Cpp :: operator precedence in cpp 
Cpp :: reference c++ 
Cpp :: C++ Program to Find the Range of Data Types using Macro Constants 
Cpp :: full implementation of binary search tree in C++ 
Cpp :: C++ cout iostream 
Cpp :: input c++ 
Cpp :: c++ delete printed characters 
Cpp :: shortest path in unweighted graph bfs 
Cpp :: remove element from c++ 
Cpp :: find factorial in c++ using class 
Cpp :: array of charcter c++ 
Cpp :: binary to decimal 
Cpp :: floyd algorithm 
ADD CONTENT
Topic
Content
Source link
Name
4+6 =