Skip to main content

Posts

Showing posts from April 12, 2017

Difference Between Procedure Oriented Programming (POP) & Object Oriented Programming (OOP)

Difference Between Procedure Oriented Programming (POP) & Object Oriented Programming (OOP) Procedure Oriented Programming Object Oriented Programming Divided Into In POP, program is divided into small parts called functions . In OOP, program is divided into parts called objects . Importance In POP,Importance is not given to data but to functions as well as sequence of actions to be done. In OOP, Importance is given to the data rather than procedures or functions because it works as a real world . Approach POP follows Top Down approach . OOP follows Bottom Up approach . Access Specifiers POP does not have any access specifier. OOP has access specifiers named Public, Private, Protected, etc. Data Moving In POP, Data can move freely from function to function in the system. In OOP, objects can move and communicate with each other through member functions. Expansion To add new data and function in POP is not so easy. OOP provides an easy wa...

Difference Between Interpreter and Compiler

Interpreter Vs Compiler : Difference Between Interpreter and Compiler We generally write a computer program using a high-level language. A high-level language is one which is understandable by us humans. It contains words and phrases from the English (or other) language. But a computer does not understand high-level language. It only understands program written in 0's and 1's in binary, called the machine code. A program written in high-level language is called a source code. We need to convert the source code into machine code and this is accomplished my compilers and interpreters. Hence, a compiler or an interpreter is a program that converts program written in high-level language into machine code understood by the computer. The difference between an interpreter and a compiler is given below: Interpreter Compiler Translates program one statement at a time. Scans the entire program and translates it as a whole into machine code. ...

PYTHON - today day script

script that tell you today day !!!!!!!! import datetime a = datetime.datetime.today().weekday() if a == 0:     print("It's Monday.") elif a == 1:     print("It's Tuesday.") elif a == 2:     print("It's Wednesday.") elif a == 3:     print("It's Thursday.") elif a ==4:     print("It's Friday.") elif a == 5:     print("It's Saturday.") elif a == 6:     print("It's Sunday.")    

PYTHON - password Generator script

 python script project --- password Generator import string from random import * letters = string.ascii_letters  digits = string.digits  symbols = string.punctuation chars = letters + digits + symbols min_length = 8 max_length = 16 password = "".join(choice(chars) for x in range(randint(min_length, max_length))) print(password)