This day I spent to study DBMS as I have the model practical exam tomorrow. I practiced with the queries based on the topics of Functions, procedures, Savepoints, Index and control structures.
Category: Uncategorized
Class in Python
Class is a user defined datatype in which the user can define his/her own variables and functions. The syntax of the class is:-
class “Name”(“parent_class”):
statement 1
statement 2
Initially we use object as the parent class. In class we can declare multiple member functions. But the member functions must have a parameter a self. This is similar to the keyword this in C++.
class Add(object):
def sum(self, a, b):
return self.a+self.b
x = add(2,3)
print(“The sum is %d” %x.sum())
Output:-
The sum is 5
Inheritance:-
Inheritance can be done by replacing the name of the object class as a user defined class.
class A(object):
def a(self, aname):
self.aname = aname
def ret_a(self):
return self.aname
class B(A):
def b(self, bname):
self.bname = bname
def ret_b(self):
return self.bname
x = A(“Chandru”)
y = B(“Python”)
print(“Name in class A %s” % y.aname)
print(“Name in class B %s” % y.bname)
Output:-
Name in class A Chandru
Name in class B Python
Multiple classes:-
Multiple class can be declared by adding the parent class name in the paranthesis of the class.
class C(Object, A , B):
statement_1
statement_2
First try
SRM is conducting a hackathon. So they announced to submit their ideas with a team of 5 members. And so in this day, I spent to get some idea to implement in the hackathon. We chose domain as travelling and we submitted the abstract of our project to the website. The results will be submitted in the website soon.
Today I was helped my father in store to arrange the grocery. This day went as usual and I went to my friend’s home to get mouse in which my mouse was broken.
Auto Draft
Today I felt better after facing the fever for a week. As day after tomorrow is my practical model exam, the whole day were spent to write my record. I also had a time with my friends.
Worst Weekend
This weekend I planed to enjoy a movie with my friends. On Thursday night I felt tired. On Friday, I became sick and that’s it my plan got broken into pieces. In the last three days, I didn’t do any proper work and I simply wasted my time. Even now I am feeling some loss of consciousness and feeling tired. It would be better if I got well before tomorrow.
Symposium
“Now you C me” my first competition which I was attended in my symposium. The competition is to debug the errors. But unfortunately I was not selected for the next round and I learnt something from that event to concentrate more on debugging.
Today I was feeling so tired as Started to play badminton in college. Day by day, I am becoming to lazy. To maintain my fitness I started Play badminton in college after the college hours. Playing after a long break made me so tired.
Project work
Today I was working to develop a website a I the project has to be submitted on day after tomorrow. I finished front end alone.
As I want to submit my mini project within this weekend, I was learning fully about the web development basics. At the end of the day, I am partially ready with the front end of the web development.