Posts

How to validate name , email,phone no with javascript and Html

 Below is the code of validation <html> <head>      <title>         Validation      </title>      <script   language = "javascript" >          function   validate () {              var   reg  =  / ^ ([ A-Za-z0-9_\- \. ]) + \@ ([ A-Za-z0-9_\- \. ]) + \. ([ A-Za-z ] {2,4} ) $ / ;              var   fname  =  document . getElementById ( 'fname' ). value ;              fname  =  fname . trim ();              var   lname  =  document . getElementById ( 'lname' ). value ;        ...

How to get all links of any website using Python

This code will extract all links form the website and will show to you Requirements 1)      beautifulsoup4 2)     requests Steps to install requirements 1) open cmd as admin 2) Type pip install beautifulsoup4 3) wait for installation 4) after completion of installation type pip install requests 5) wait for installation completion Code import requests from bs4 import BeautifulSoup url = "https://www.python.org" links = [] website = requests.get(url) website_text = website.text soup = BeautifulSoup(website_text) for link in soup.findAll('a'):     links.append(link.get('href')) for link in links:     if not link:         pass     elif "http" in link :         print(link)     else:         print(url+link) print(len(links)) Comment down queries below if any are there

How to learn programming if do not have any interest in programming.

So Todays Blog is about how to learn programming if someone does not have any type interest to learn to code or facing Difficulties in learning programming. First Step If you do not want to code and have interest in any other field so just leave the field of coding and move on to another field you like, but if you like this field so be mentally prepared What is programming Not a pure definition but to explain programming is like talking with computer in a particular language like you talk in English or any other language with others . you just have to think you are communicating with the computer like example  print("hello world") in python  in this statement you just have to think you are telling computer in language python that print "hello world " you just ordering computer to act like what you decide, In this manner you have to just imagine yourself And to learn to program From where to learn You will get many YouTube videos to learn .YouTube is the Best platfor...

Never Ending Loop but when will end doesn't know program in python

Image
About the Program In this program we are going to code the simple python program with loop. But a catch is when the loop will terminate no one knows maybe never maybe in 5 minutes or maybe in 5 sec  Program import random  a = 137  print(a)  b = 0  while True:      b+=1      r=random.randint(1,10000000000)      print(str(b)+" "+str(r))      if r==a:          print(r," is succesfully founded")          break  What is happening with the code  The code is going into the loop and in loop it is taking a random number and checking with our initialized number if found it gets exit comment down the number when your loops gets exit. tip :- to execute program fast just change the    r=random.randint(1,10000000000) to     r=random.randint(1,1000) 

Flutter the upcoming generation software development kit which uses Dart language

Image
What is Flutter Flutter is an open-source UI software development kit created by Google. It is used to develop applications for Android, iOS, Windows, Mac, Linux, Google Fuchsia and the web.  Flutter works with existing code, is used by developers and organizations around the world, and is free and open sour ce. Flutter is a solution for creating cross-platform mobile applications with beautiful UI. Flutter’s way of designing views is similar to the web applications, so you can find many analog ies to HTML/CSS. its a new open source library for creating mobile applications. History The first version of Flutter was known as codename "Sky" which ran on the Android operating system I n 2015 Dart developer summit the flutter was announced by the google  During the keynote of Google Developer Days in Shanghai, Google announced Flutter Release Preview 2 which is the last big release before Flutter 1.0.  Flutter 1.0 was released at the Flutter Live event, denoting the first "...

Rectangle with pencil in paint with the help of Python programming

Image
How to create rectangle with the help of pencil in python as per below? Here is the answer. Requirements :- PYAUTOGUI Library of the Python  Code import pyautogui import time pyautogui.moveTo(320,320) time.sleep(0.1) pyautogui.mouseDown() x=320 y=320 while y<=420: pyautogui.moveTo(x,y) while x<=540: x=x+110 pyautogui.moveTo(x,y) x=320 y=y+1 pyautogui.mouseUp() Steps to perform operation: !)     Open Visual Studio Code (if not installed download from here ) 2)     Create python file then Copy and paste the code 3)     Open paint -> select pencil or brush and arrange window as given below 4)     Run the code . 5)     wait for the code to stop Done ! you had drawn rectangle with the help of the pencil comment down below for any query. (Caution : Modifying code can make code operate in infinite loop so perform operation with caution)

Visual Studio Code - the code editor for Python with great features

Image
        Visual Studio Code is a source-code editor developed by Microsoft for Windows, Linux and macOS. This code editors has many features like  debugging, syntax highlighting, intelligent code completion, snippets, and code refactoring .we can add more functionality to editor with the help of extensions. The code editor is free to use .         Visual Studio Code was ranked the most popular developer environment tool In the Stack Overflow 2019 Developer Survey         VS code(Visual Studio Code)supports C++, C#, CSS, Dockerfile, Go, HTML, Java, JavaScript, JSON,  Less, Markdown, PHP, PowerShell, Python, SCSS, T-SQL, Typescript. Prerequisites Python 3 installed on your machine and a local development environment set up Setup of vs code for python in windows 1)      Download visual studio code from  https://code.visualstudio.com/  for windows 2)    Open Visual Studio Code...