Showing posts with label algorithm. Show all posts
Showing posts with label algorithm. Show all posts

Saturday, September 12, 2020

387 - python program to find sum and product of two numbers

 387 - python program to find sum and product of two numbers


 

python program to find sum and product of two numbers

================================================

 

Code :

# find sum and product of two numbers

x = int(input('Enter first number:'))

y = int(input('Enter second number:'))

#display sum

print('The sum of {0} and {1} is {2}'.format(x,y,x+y))

#display product

print('The product of {0} and {1} and {2}'.format(x,y,x*y))

#display both sum and product

print('the sum of {0} and {1} is {2} and product of {0} and {1} is {3}'.format(x,y,x+y,x*y))

 

Output :

Enter first number:11
Enter second number:22
The sum of 11 and 22 is 33
The product of 11 and 22 and 242
the sum of 11 and 22 is 33 and product of 11 and 22 is 242

 

 

 

 

 


Friday, September 11, 2020

Example of a Recommender System

  Example of a Recommender System


 

Example of a Recommender System

================================

Recommender Systems such as one used

over Amazon , helps a customer make

purchases based on the criteria such as

previous product purchases or products

that complement or supplement a current

choice .


Thursday, September 10, 2020

Procedure to create an array using logspace function in python

 Procedure to create an array using logspace function in python


 

  Procedure to create an array using

        logspace function in python

============================================================

 

The logspace() function is somewhat similar to that

of a linspace() function .The linspace function creates

an array of evenly spaced numerical points on a linear

scale of numbers . Similarly, a logspace function can

be used to create an array of evenly spaced points but

on a logarithmic scale . Below is the expression for

usage of the logspace() function :

 

logspace(start,stop,0)

 

The logspace() function starts at a value which is 10 to

the power of 'start' and it ends at a value which is 10 to

the power of 'stop' . If 'n' is not specified , then its value

is taken by default as 50.

 

 

 


create arrays using arange() function in python

 create arrays using arange() function in python


 

 

create arrays using arange() function in python

========================================

 

The arrange() function in numpy is same as range()

function in python . The arrange function is used in the

following format :

arrange(start,stop,stepsize)

This creates an array with a group of elements from 'start' to one element prior to 'stop' in steps of 'stepsize'.If the

'Stepsize' parameter is omitted , then it is taken as 1 .If the

'start' parameter is omitted ,then start is taken as 0.

 

 

import numpy as np

np.arange(10)

output

[1,2,3,4,5,6,7,8,9]

 

import numpy as np

np.arange(5,10)

output

[5,6,7,8,9]

 

import numpy as np

np.arange(1,10,3)

output

[1,4,7]

 

import numpy as np

np.arange(10,1,-1)

output

[10,9,8,7,6,5,4,3,2]

 

import numpy as np

np.arange(0,10,1.5)

output

[0 , 1.5 , 3 , 4.5 , 6 , 7.5 , 9]

 

import numpy as np

np.arange(2,21,2)

output

[2,4,6,8,10,12,14,16,18,20]

 

 

 

 


Friday, September 4, 2020

A short summary on the concpet of usage of categorical variables in machine learning

 A short summary on the concpet of usage of categorical variables in machine learning 



A short summary on the concept of page ranking and TF-IDF values

 A short summary on the concept of page ranking and TF-IDF values



A short summary on the concept of SVM algorithm in machine learning part -02

 A short summary on the concept of SVM algorithm in machine learning part -02



A short summary on the concept of SVM algorithm in machine learning

 A short summary on the concept of SVM algorithm in machine learning



Thursday, September 3, 2020

A short summary on ROC curve and what does it stand for

 A short summary on ROC curve and what does it stand for 



what is over-fitting - a short summary

 what is over-fitting - a short summary



a very short summary upon Naive Bayes Theorems and Algorithms

 a very short summary upon Naive Bayes Theorems and Algorithms



goal of cross-validation in machine learning

 goal of cross-validation in machine learning



A summary on False positive Cancer Case and its analysis in Statistics

 A summary on False positive Cancer Case and its analysis in Statistics



A short summary on Collaborative Filtering

 A short summary on Collaborative Filtering



method to avoid over-fitting and under-fitting over a data sample or data set in machine learning and statistics

 method to avoid over-fitting and under-fitting over a data sample or data set in machine learning and statistics



Saturday, August 29, 2020

fundamental difference between machine learning and deep learning

 fundamental difference between machine learning and deep learning



A summary on Machine Learning

 A summary on Machine Learning



A summary on K-Nearest Neighbour Algorithm - KNN

 A summary on K-Nearest Neighbour Algorithm - KNN



how to work in a Random Forest algorithm using model

 how to work in a Random Forest algorithm using model



how regularly should an algorithm be updated in machine learning

 how regularly should an algorithm be updated in machine learning



Durga Puja in Odisha

 Durga Puja in Odisha