Skip to content

Instantly share code, notes, and snippets.

View ak-alam's full-sized avatar
🎯
Focusing

Akbar Alam ak-alam

🎯
Focusing
  • Earth
  • 18:04 (UTC -12:00)
View GitHub Profile
import numpy as np
import pandas as pd
eps = np.finfo(float).eps
from numpy import log2, log
df = pd.read_csv('data.csv', sep = ',')
#this code I used for only values of entropy of target and all features of data.
entropy_node = 0 #initilaize entropy
values = df.Target.unique()
@ak-alam
ak-alam / gist:2439f6bd31fae5f19fff11644364d996
Last active February 27, 2020 21:46
01 Character Input (first exercise from practice python
"""Create a program that asks the user to enter their name and their age. Print out a message addressed to them that tells them the year that they will turn 100 years old.""""
name = input("Enter your name: ")
age = int(input("Enter your age: "))
turn_100 = (2020 + (100 - age))
print("Your will turn 100 in year ",turn_100)