Posts

Final Project of Using Python to Interact with the Operating System

  What we'll do in Brief Use regex to parse a log file for keyword INFO and ERROR Append and modify values in a dictionary| Two separate dictionaries for INFO and ERROR Write to a file in CSV format |, Two CSV files Move files to the appropriate directory for use with the CSV->HTML converter| The conversion program is already provided. We have not to create/develope conversion utility. #ticky_check written by Me and with My own Login without using import csv utility only in 31 lines a in very simple way #!/usr/bin/env python import re import operator users={} errors={} with open('syslog.log') as logfile:     for line in logfile:         line=line.strip() # to trim \n         user = re.search(r'\((.+)\)$',line)         if user[1] not in users:             users[user[1]]=(0,0) #(info,error)         if 'INFO' in line:             #s...

Some Python Simple Tasks or little changing to do

  1. Convert DictionaryFile into csv file 2. Convert csv file into DictionaryFile csv.DictReader(mfile.csv) 2. csv file into Html file

What are you going to do in 2023? Tops 5 skills to get! By David Bomal

  Some suggestion for me by myself  after watching the video of Bomal 0. I have not waste my times to see the entertainment videos/clips. 1. Python  (at this stage I do not know about other languages like GOLANG / RUST as mentioned by Bomal in the video) I think only Python is OK for me. I have to be an Expert in Python only  2. Linux As I have 30+ years experience on SCO UNIX. UNIX is father of Linux es (daughters) 3. To learn the Machine Learning then DataScience www.kaggle.com  4. Some knowledge of Clouds I think for myself to go Google Clouds I think its stuff  and certification and training would be FREE as its new in cloud computing and a very big competator of AWS.Amazon.com 5. usage and interaction with Chat-GPT 6. Also I have to see what is OpDev I think it is some thing concern with software developement. 7. CompTIA.com CERTIFICATIONS Like compTIA Linux+  compTIA Cloud+ By David Bomal: What are you going to do in 2023? Tops 5 skills to get! B...

My First Python Project at my company

  Description: There were 3 text files of attendance After merging three file I made  a report.  Porblem was some all employess are not present/exists in all text files Also I read some information from my legacy foxplus master.dbf code is as under -------------------------------------------------------------------------------------  def fetchline(infile,mdays):     with open(infile, "r", encoding="utf8") as txtf:         retline=[]         for line in txtf:             if empcode in line:                 retline = line.split("\t")                 return retline[2:] ## leave the code and name fields     txtf.close()     if len(retline) < 3:         retline=['A' for i in range(mdays)]     return retline def emplist(infile):        with ope...

Course No 2 Using Python to Interact with the Operating System Rough Notes

Image
MAIN COURSE  Google IT Automation with Python Professional Certificate Having 6 crouse 1st course was Python Crash which I have DONE got certificate . My friend say 'bati bana kar gand meen dalo' Course No 2 Using Python to Interact with the Operating System ------------------------------ course 2 week 5 added  By inputting emp name the program will return its email address By inputing   Blossom Gill program will return his email aress blossom@abc.edu Our job is to  1. add a test means  test cases like basic_test Edge_test see  the bugs,  2. make the necessary corrections in  email.py Python file to correct the bugs   3. verify that all the tests pass to make sure the script works!  4.  This is The End Lab . Best of luck! and Congrautulations Once again, in other words, same matter/problem as mentioned above What you'll do In this lab, you will: Write a simple test (basic test )to check for basic functionality Write a test...