Recently took a breath of Hanshunping teacher to read the Linux video tutorial, oneself also in the process of learning to do some notes, recorded as follows, hope to help some students like to study Linux, but also in the cloud back up notes it, in
To create a class:
#!/usr/bin/python# Filename:simplestclass.pyClass Person:Pass # a empty blockp = person ()Print P$ python simplestclass.py
We use the class name followed by a pair of parentheses to create an object/instance. For verification,
The first day of the month on which the given date is calculated
The trick is to calculate the
number of time intervals between the current date and "1900-01-01" and then add it to "1900-01-01" to get a special date, a technique that can be
Date and time function library {often forget}Checkdate: Verify the correctness of the date.Date: Formats the time of the server.Strftime: Formats the server's time locally.GETDATE: Get time and date information.Gettimeofday: Get the current
Definitions and usageThe strftime () function formats the local time/date according to the locale setting.
GrammarStrftime (format,timestamp) parameter descriptionFormat is optional. Specify how the results are returned.Timestamp optional.Tips and
One, Time moduleLet's start by introducing some of the time-representation methods you'll use.(1) Timestamp: Refers to how many seconds have elapsed since the beginning of the Unix period, such as the first article of the result;(2) Time tuple: In
The Java language is an object-oriented programming language that supports network computing. The Java language absorbs the advantages of the Smalltalk language and the C + + language, and adds other features,such as support concurrent programming,
Java is a simple, object-oriented, distributed, interpretive, robust, secure, structured-neutral, portable, high performance, multi-threaded static language. So what are the features of the Java language?1. The Java language is simpleThe syntax of
The const is initialized in the place where it was established. The const modifier cannot be modified.About the static const type is: All objects are shared and unchanging data.http://blog.csdn.net/luoweifu/article/details/20288549Output local time:
1. Installing CronologOfficial website Download: http://cronolog.org/usage.html./configureMake;make InstallDefault installation Location:# which Cronolog/usr/local/sbin/cronolog2. Configure the split Tomcat logEdit the catalina.sh file under the
This section of this article refers to the Java Virtual Machine specification (Java SE 7 version) of the Chinese translation and Zhou Zhiming of "in-depth understanding of Java Virtual Machine", plus personal understanding. The original book on the
1. Two ways to get the current time:
Copy Code code as follows:
Import Datetime,time
now = Time.strftime ("%y-%m-%d%h:%m:%s")
Print now
now = Datetime.datetime.now ()
Print now
2. Get the last day of last month's
JavaScript is used in object-oriented programming, or object-oriented programming. The so-called "object-oriented programming", meaning that JavaScript can be involved in the scope of the division into large and small objects, objects continue to
JavaScript Reference Tutorials
JavaScript is used as "object-oriented programming" or "object-oriented programming." The so-called "object-oriented programming", meaning that JavaScript can be involved in the scope of the division into large and
1. Use CTime class (get system current time, accurate to second)
CString str;
Obtain the system time
CTime TM;
Tm=ctime::getcurrenttime ()//Get system date
Str=tm. Format ("Now time is%y year%m month%d");
MessageBox (STR,NULL,MB_OK);
In the beginning, please reader very very patiently read the following several boring terms to explain, originally this does not conform to the style of this tutorial, but please reader understanding, because you will be sure to read the boring
(1): C + + Get current system time:http://www.cnblogs.com/mfryf/archive/2012/02/13/2349360.html
However, when the calculation algorithm time is time-consuming, do not forget second, can not only use milliseconds to reduce, otherwise negative, if
Checkdate:
Verify the correctness of the date.
Date:
Format the time of the server.
Strftime:
The time of the server is formatted locally.
GETDATE:
Get time and date information.
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.