A digit or a letter
Practice
3 (10 votes)
String
Implementation
Recruit
Basic programming
Algorithms
Easy
String algorithms
Approved
Hashing algorithm
Hashing algorithm
Problem
89% Success 944 Attempts 20 Points 1s Time Limit 256MB Memory 1024 KB Max Code

You are given a string \(S\) of \(N\) characters \(a_i\). Determine the number of digits and the number of English letters in \(S\).

Input format
First line: String \(S\) of length \(N\)

Output format

  • First line: Print the number of digits in \(S\)
  • Second line: Print the number of English letters in \(S\)

Constraints

\(1 \le N \le 10\)
All \(a_i\) characters are the standard ASCII characters.

Please login to use the editor

You need to be logged in to access the code editor

Loading...

Please wait while we load the editor

Loading...
Results
Custom Input
Run your code to see the output
Submissions
Please login to view your submissions
Similar Problems
Points:20
13 votes
Tags:
String AlgorithmsAlgorithmsHashing Algorithm
Points:20
1 votes
Tags:
Easy
Points:20
13 votes
Tags:
String AlgorithmsHashing AlgorithmAlgorithms