1,760
edits
Changes
→selected items from a list to make useful data object
= selected items from a list to make useful data object=
== login date and logout date ==
Login date in YYYYmmmdd format:
<pre>
login_date = word_list[7]+word_list[4]+word_list[5]
print('Login date:',login_date)
</pre>
The output will be:
<pre>
Login date: 2018Feb13
</pre>
Logout date in YYYYmmdd format:
<pre>
logout_date = word_list[13]+word_list[10]+word_list[11]
print('Logout date:, logout_date)
</pre>
The output will be:
<pre>
Logout date: 2018Feb13
</pre>
== login time and logout time ==
<pre>
login_time = word_list[6]
print('Login time:',login_time)
</pre>
The output will be:
<pre>
Login time:
</pre>
=manipulate data objects: date, time, user name, host IP=