<jupyter_start><jupyter_text>time<jupyter_code>import datetime as dt
import time as tm
tm.time()
dtnow = dt.datetime.fromtimestamp(tm.time())
dtnow
dtnow=dt.datetime.fromtimestamp(tm.time())
dtnow
print(dtnow)
dtnow.year
dtnow.month
import datetime as dt
import time as tm
tm.time()

dtnow=dt.datetime.fromtimestamp(tm.time())
dtnow
print(dtnow)
dtnow.second
delta=dt.timedelta(days=100)
delta
print(delta)
today=dt.date.today()
today
print(today)
class Person:
    department = 'School of Information' #a class variable

    def set_name(self, new_name): #a method
        self.name = new_name
    def set_location(self, new_location):
        self.location = new_location
person = Person()
person.set_name('<NAME>')
person.set_location('46, Nairobi, Kenya')
print('{} live in {} and works in the department {}'.format(person.name, person.location, person.department))
a,b,c=1,2,'kadas'
print(c)
print(1)
str = 'Hello World!'
print(str)
print(str[0])
print(str[2:5])
print(str[3:])
print(str*3)
print(str + 'TEST')
s=10
p=2

var1 = 100
if var1:
   print("1 - Got a true expression value")
   print(var1)
var2 = 0
if var2:
   print("2 - Got a true expression value")
   print(var2)
print("Good bye!")
var = 240
if var < 200:
   print("Expression value is less than 200")
   if var == 150:
      print("Which is 150")
   elif var == 100:
      print("Which is 100")
   elif var == 50:
      print("Which is 50")
   elif var < 50:
      print("Expression value is less than 50")
else:
   print("Could not find true expression")

print("Good bye!")
count = 0
while (count < 9):
   print('The count is:', count)
   count = count + 1
count = 0
while (count < 9):
   print('The count is:', count)
   count = count + 1

import numpy as np
import os
cwd = os.getcwd()
cwd<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.14054656999442275, 'fraction_numerical': 0.03513664249860569, 'mean_word_length': 4.184971098265896, 'pattern_counts': {'":': 0, '<': 10, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '249685', 'license': 'Apache-2.0', 'n_tokens_mistral': 693, 'n_tokens_neox': 643, 'n_words': 192, 'path': '1-python/practice 1.ipynb', 'repo_name': 'Kadas36/Data-science-project-', 'size': '1797'}