Programming

Python Functions ( lambda function, map function, filter function)

Function is a block of code which performs specific task. How to call a function What is lambda function? Lambda function is anonymous function. No function name when we use lambda function. Lambda function has many argument but we can define only single expressions. To define a lambda function we will use lambda keyword. Lambda …

Python Functions ( lambda function, map function, filter function) Read More »

Flow control statement in Python

If and else statement in Python If we need to add some conditional statement then we will use if, else conditions. Loops in Python While Loop While loop executes statement repeatedly until condition is true. For Loop For loop iterate our sequence. Sequence is a list, tuple, dictionary. For is the basic keyword like other …

Flow control statement in Python Read More »

Data Structures in Python

In python their are four types of basic data structures Tuple Tuple is an ordered collection of elements enclosed within brackets. Tuples are immutable. List List is an ordered collection of elements enclosed within []. Lists are mutable. Dictionary Dictionary is an unordered collection of key-values pairs enclosed with {}. Dictionary is mutable. Set Set …

Data Structures in Python Read More »

How to convert image to text using OCR?

Yes, it is possible. We can extract text from images with the help of Tesseract OCR library. Let’s start how can we do this? Below code extract text from the above images: Output: “Word count writing mistakes plagiarism Check Now” Firstly we need to add Tesseract-OCR library in our system. Create a new Python file …

How to convert image to text using OCR? Read More »

Python String functions

Len Function Len function used to count character in string. mystring = “Hello World” print(len(mystring)) Output: 11 Lower function Lower function used to convert string in lower case. mystring = “Hello World” print(mystring lower()) Output: hello word   Upper function Upper  function used to convert string in upper case. mystring = “Hello World” print(mystring.upper()) Output: HELLO WORLD Find …

Python String functions Read More »