Today we will learn how to make QR using Python. For that, we are using a package called pyqrcode. It required only 3 lines of code to generate a QR code. In this example, we create a QR code containing the parseltongue’s URL. Let us dive into the code
import pyqrcode qr_code = pyqrcode.create("https://parseltongue.co.in") qr_code.svg('qrcode.svg')
File called qrcode.svg is generated in the current folder.
If we scan the QR code we can see that URL is encoded in this QR code. To learn more about this package please click here.
I hope you have learned something from the post. Please share your valuable suggestion with email@example.com