Monday 22 November 2021

Sequence DataType Part - I

Sequence data type


•   Strings - Sequence of characters - " (or) '




•   Tuples - Sequence of compound data - ()




•   Lists - Sequence of multi-data type objects - []




•   Arrays - Sequence of constrained list of objects (all objects of same datatype) using array module from array package




•   Dictionary- Sequence of key-value pairs - {}




•   Sets - Sequence of unordered collection of unique data





•   Range - Used for looping - using built-in range( )










Join us: https://t.me/jupyter_python

Sunday 21 November 2021

Introduction to java | Java tutorials | History of Java | JDK | JVM | JRE | Different Types of Java Platforms

What is Java?

Java is a class-based object-oriented programming language.

It is the most popular programming language.

Building web and desktop applications.

The language of choice for Android programming.

 

Java Platform

Java Platform is a collection of programs that help programmers to develop and run Java programming applications efficiently.

It includes an execution engine, a compiler, and a set of libraries in it.

It is a set of computer software and specifications.

James Gosling developed the Java platform at Sun Microsystems, and the Oracle Corporation later acquired it.

Java is a multi-platform, object-oriented, and network-centric language. It is among the most used programming language. Java is also used as a computing platform.

What is Java used for?

It is used for developing Android Apps

Helps you to create Enterprise Software

Wide range of Mobile java Applications

Use for big data Analytics.

Java Programming of Hardware devices

Used for Server-Side Technologies like Apache, JBoss, GlassFish, etc.

 

History of Java Programming Language

The Java language was initially called OAK.

it was developed for handling portable devices and set-top boxes.

In 1995, Sun changed the name to “Java” and modified the language to take advantage of the burgeoning www (World Wide Web) development business.

Later, in 2009, Oracle Corporation acquired Sun Microsystems and took ownership of three key Sun software assets: Java, MySQL, and Solaris.

Java Versions

JDK Alpha and Beta

   1995

JDK 1.0

23rd Jan 1996

JAVA SE 15

           15th Sep 2020 (latest Java Version)

 

 

Java Features

  • It is one of the easy-to-use programming languages to learn.
  • Write code once and run it on almost any computing platform.
  • Java is platform-independent. Some programs developed in one machine can be executed in another machine.
  • It is designed for building object-oriented applications.
  • It is a multi threaded language with automatic memory management.
  • It is created for the distributed environment of the Internet.
  • Facilitates distributed computing as its network-centric.

Java Development kit (JDK)

 

JDK is a software development environment used for making applets and Java applications.

Java developers can use it on Windows, macOS, Solaris, and Linux.

It is possible to install more than one JDK version on the same computer.

Why use JDK?

 

· JDK contains tools required to write Java programs and JRE to execute them.

· It includes a compiler, Java application launcher, Applet viewer, etc.

· Compiler converts code written in Java into byte code.

Java Virtual Machine (JVM):

 

Java Virtual Machine (JVM) is an engine that provides a runtime environment to drive the Java Code or applications.

It converts Java bytecode into machine language.

Why use JVM?

  • JVM provides a platform-independent way of executing Java source code.
  • It has numerous libraries, tools, and frameworks.
  • Once you run a Java program, you can run on any platform and save lots of time.
  • JVM comes with JIT (Just-in-Time) compiler that converts Java source code into low-level machine language. Hence, it runs faster than a regular application.

Java Runtime Environment (JRE)

JRE is a piece of software that is designed to run other software.

It contains the class libraries, loader class, and JVM.

If you are not a programmer, you don’t need to install JDK, but just JRE to run Java programs.

Why use JRE (Java Runtime Environment)

  • JRE contains class libraries, JVM, and other supporting files. It does not include any tool for Java development like a debugger, compiler, etc.
  • It uses important package classes like math, swing, util, lang, awt, and runtime libraries.
  • If you have to run Java applets, then JRE must be installed in your system.

 

Different Types of Java Platforms

1.       Java Platform, Standard Edition (Java SE):

Java SE’s API offers the Java programming language’s core functionality.

It defines all the basis of type and object to high-level classes.

It is used for networking, security, database access, graphical user interface (GUI) development, and XML parsing.

 

2.       Java Platform, Enterprise Edition (Java EE):

The Java EE platform offers an API and runtime environment for developing and running highly scalable, large-scale, multi-tiered, reliable, and secure network applications.

 

3.       Java Programming Language Platform, Micro Edition (Java ME):

The Java ME platform offers an API and a small-footprint virtual machine running Java programming language applications on small devices, like mobile phones.

 

API :  Application programming interface

An API is a set of programming code that enables data transmission between one software product and another. It also contains the terms of this data exchange.

 

4.       Java FX: 

JavaFX is a platform for developing rich internet applications using a lightweight user-interface API. It user hardware-accelerated graphics and media engines that help Java take advantage of higher-performance clients and a modern look-and-feel and high-level APIs for connecting to networked data sources.

First Program :

 

Class abc {

Public static void main(String args[]){

System.out.println(“Hello World”);

}

}

 


Types of Operators in Python

Assignment Operator 

Assignment operators are used to assign values to variables.

 There are 5 types of assignments operators 




Relational or Comparison Operator


Relational operator tests numerical equalities and inequalities between two operands and returns a boolean value

All operators have same precedence

So now, we will create two variables x and y with values 5 and 7 respectively and test the operators on them.




       
Logical Operators

Logical Operators are used when operands are conditional statements and it returns boolean value.

In python, logical operators are designed to work with scalars or boolean values.




 Join us: https://t.me/jupyter_python

Operators in Python


Operators and Operands

Operators are special symbol that help in carrying out an assignment operation or arithmetic or logical computation

Value that the operator operates on is called operand

Example:

2 + 3 = 5 

Here, plus sign ("+") is the Operator and "2","3" are the Operands.

Arithmetic Operators 

Used to perform mathematical operations between two operands.

So now, we will create two variables as a = 10 and b = 5 and perform some basic operations on them.




Hierarchy of arithmetic operators


Example:

Monday 11 October 2021

Saturday 9 October 2021

Introduction to Python


Evolution of Python.

 -Python was developed by Guido Van Rossum in the late eighties at the ' National Research Institute       for Mathematics and Computer Science, at Netherlands.

 Python Editions 

  - Python 1.0
  - Python 2.0
  - Python 3.0

Advantages of  using Python

- Python has several features that make it well suited for data science

- Open source and community development 

- Developed under Open Source Intiative approved license making it free to use and      distribute even commercially

- Syntax used is simple to understand and code 

- Libraries designed for specific data science tasks 

- Combines well with majority of the cloud platform service providers

Integrated development enviroment (IDE)

- Software application consisiting of a cohesive unit of tools required for development

- Designed to simplify software development

- Utilities Provided by IDEs include tools for managing, compiling, deploying and debugging software

Feature of IDE 

- IDE should centralize three key tools nthat form the crux of software development 

- Syntax and error highlighting 

-  Code completion 

- Version control

Commonly used IDEs

-Spyder
-PyCharm
-Jupyter Notebook
-Atom

But in this course we are going to be looking at jupyter notebook; and that is primarily because it is a very good software that has been developed only for data science and python; and it as an interface that is very very appealing and easy to use for beginners.

Jupyter Notebook

-Web application that allows creation and manipulation of notebook documents called 'notebook',

-Supported across Linux, Mac Os X and windows platforms.

-Available as open source version.

-Bundled with Anaconda distribution or can be installed seperately.

-Supports Julia, Python, R and Scala.
 
-Consists of ordered collection of input and output cells that contain code,text,plots etc.

-Allows sharing of code and narrative text through output format likePDF,HTML etc.



Wednesday 6 October 2021

Control structures [if elif]


Control structures 

if elif

  •    Whenever you want to execute certain commands only when the certain condition is satisfied. 
  •    So, in that case you can go for if else statements, the condition can also be single or you can also give multiple condition, in that case you will have multiple else statements.
  • In the image below you can see this, more clearly.

     



  • So, first we will look into the if else family of constructs, if else and If-elif-else are a family of constructs, where a condition is first checked, if it is satisfied only then the operations will be performed. 
  • If, the condition is not satisfied the code exits the construct or moves on to the other options. So, whenever we use just an if statement or with an else statement or with using multiple if's and multiple else clause. 
  • The first check would be the condition, whenever the condition is satisfied only then the code will be executed or the statement will be executed, otherwise the code exits the construct itself and moves to the other options. So, that is how the if else family of the constructs works. 


  • Let us see different task for each construct. So, first we will look into if construct, the command would be if expression colon and statements in the next line.
  • If is a key word, if the condition is satisfied whatever condition you have given it under the expression, then the statements will get executed. Otherwise, the code exit the construct itself. 
  • Next, we will move ahead and see what is the syntax would be for If-else construct
  • It forms a basis from the if construct, wherever we have given the first statement, using the if keyword and followed by if keyword you have to give the expression to be checked, that is where the condition to be specified.

Join us: https://t.me/jupyter_python

Tuesday 5 October 2021

Introduction to Python for Data Science

What is Data Science?

  • Data Science is the art of analyzing using statistics and machine learning techniques raw data with a perspective of drawing valuable insight from it.
  • Data Science is used in many industries to allow them to make better business and decisions, and in the sciences to test models or theories.
  • This requires process of inspecting, cleaning, modelling, analyzing and interpreting raw data.




Why Using Python?

  • Python libraries provide basic key features sets which are essential for data science.
  • Data Manipulation and Pre-Processing
Python's pandas library offers a variety of functions and data wrangling process


Join us: https://t.me/jupyter_python

Operations On Dataframe in Python [Part II]


Concise summary of Dataframe.


  • So, next we are going to see about how to get the concise summary of DataFrame.

  • So, there is a command called info that returns a concise summary of a DataFrame, the concise summary includes the data type of index; index being the row labels, the data type of row labels is what the output gives as well as it gives the data type of columns, it also gives the count of non-null values.

  • Basically, how many filled values are there in your DataFrame. 

  • Also, it gives the memory usage of the DataFrame and the syntax would be you use the info command along with the DataFrame name.

Syntax = DataFrame.info()












Join us: https://t.me/jupyter_python

Operations On Dataframe in Python

Checking data types of each Column in a Data Frame.


  • If you want to check the data type of each column, because whenever you have been given a data, you want to really check what is the structure of the data; that means, which variable has which data type?
  • In, that case you can use dtypes, because that returns a series with the data type of each column and the syntax would be you use dtypes along with the Data Frame name.
  • So, Data Frame.dtypes will give you a series with the data type of each column

Here is the syntax.

Syntax = DataFrame.dtypes

                                      



Count of unique data types

  • So, now we have an overall idea about what are the data types that we are going to work with using the cars_data. 
  • There is also an option where you can get the count of unique data types available in your Data Frame.
  • So, in that case get_dtype_counts, returns the counts of unique data types in the data frame.


Here is the syntax.

Syntax = get_dtype_counts()





Selecting data based on data types

  • So, now we also have an overall idea about the count of unique data types that we are going to handle with. 

  • So, now, we know about how to get the data type of each variables. So, there might be cases where you want to perform the operations only on a numerical data type.

  • Similarly, there can be cases where you are going to work with only categorical data type.



Here is the syntax.

Syntax = pandas.DataFrame.select.dtypes()












Join us: https://t.me/jupyter_python

Popular Posts

Categories

AI (27) Android (24) AngularJS (1) Assembly Language (2) aws (17) Azure (7) BI (10) book (4) Books (115) C (77) C# (12) C++ (82) Course (62) Coursera (178) coursewra (1) Cybersecurity (22) data management (11) Data Science (91) Data Strucures (6) Deep Learning (9) Django (6) Downloads (3) edx (2) Engineering (14) Excel (13) Factorial (1) Finance (5) flutter (1) FPL (17) Google (19) Hadoop (3) HTML&CSS (46) IBM (25) IoT (1) IS (25) Java (92) Leet Code (4) Machine Learning (44) Meta (18) MICHIGAN (5) microsoft (3) Pandas (3) PHP (20) Projects (29) Python (746) Python Coding Challenge (201) Questions (2) R (70) React (6) Scripting (1) security (3) Selenium Webdriver (2) Software (17) SQL (40) UX Research (1) web application (8)

Followers

Person climbing a staircase. Learn Data Science from Scratch: online program with 21 courses