Question: python 3- Write Python code using Regular Expression to validate the address base on the below requirements. Below is a correct Format of the Ethereum
3- Write Python code using Regular Expression to validate the address base on the below requirements. Below is a correct Format of the Ethereum Blockchain Address: 1. An ETH address is an identifier containing 26-35 alphanumeric characters. 2. An ETH address starts with the numbers 1,3 , or eth1. 3. It contains digits in the range of 0 to 9. 4. It allows uppercase as well as lowercase alphabet characters. 5. There is one exceptional point to be noted: The uppercase letter O, the uppercase letter I. the lowercase letter I, and the number 0 are not used to avoid visual ambiguity. 6. It should not contain whitespaces and other special characters. Sample Input and Output: Input: 1RAHUEYstWetqabcFn5Au4m4GFg7xJaNVN2 Output: True Input: 3J98t1RHT73CNmQwertyyWrnqRhWNLy Output: True Input: b1qarsrrr7ASHy5643ydab9re59gtzzwfrah Output: False Explanation: Invalid ETH address as it starts with " b " Input: oJ98t1RHT73CNmQwertyyWrnqRhWNLy Output: False Explanation: Invalid ETH address as it starts with 0
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
