>>> import os
>>> import datetime
>>> file = "my_file.txt"
>>> os.stat(file).st_ctime
1483323862.8774118
>>> os.path.getmtime(file)
1483323862.873167
>>> os.path.getmtime(os.path.getmtime(file))
KeyboardInterrupt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
ALL | |
All messages in the mailbox; the default initial key for | |
ANDing. | |
ANSWERED | |
Messages with the \Answered flag set. | |
BCC | |
Messages that contain the specified string in the envelope | |
structure's BCC field. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
* Minimalistic implementation of the XModem/YModem protocol suite, including | |
* a compact version of an CRC16 algorithm. The code is just enough to upload | |
* an image to an MCU that bootstraps itself over an UART. | |
* | |
* Copyright (c) 2014 Daniel Mack <github@zonque.org> | |
* | |
* License: MIT | |
*/ |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo sh -c 'echo "deb http://cran.rstudio.com/bin/linux/ubuntu trusty/" >> /etc/apt/sources.list' | |
gpg --keyserver keyserver.ubuntu.com --recv-key E084DAB9 | |
gpg -a --export E084DAB9 | sudo apt-key add - | |
sudo apt-get update | |
sudo apt-get -y install r-base libapparmor1 libcurl4-gnutls-dev libxml2-dev libssl-dev gdebi-core | |
sudo su - -c "R -e \"install.packages('shiny', repos = 'http://cran.rstudio.com/')\"" | |
sudo su - -c "R -e \"install.packages('devtools', repos='http://cran.rstudio.com/')\"" | |
sudo su - -c "R -e \"devtools::install_github('daattali/shinyjs')\"" | |
sudo su - -c "R -e \"devtools::install_github('bioc/shinyjs')\"" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from pymongo import MongoClient | |
from odo import odo | |
import pandas as pd | |
# open connection | |
connection = MongoClient() | |
# pandas df creation | |
DF = pd.DataFrame({'A': [1,2,3,4,5,6,7], 'B':[10,20,30,40,50,60,70]}) | |
# database connection |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo sh -c 'echo "deb http://cran.rstudio.com/bin/linux/ubuntu trusty/" >> /etc/apt/sources.list' | |
gpg --keyserver keyserver.ubuntu.com --recv-key E084DAB9 | |
gpg -a --export E084DAB9 | sudo apt-key add - | |
sudo apt-get update | |
sudo apt-get -y install r-base libapparmor1 libcurl4-gnutls-dev libxml2-dev libssl-dev gdebi-core | |
sudo apt-get install libcairo2-dev | |
sudo apt-get install libxt-dev | |
sudo apt-get install git-core | |
sudo /bin/dd if=/dev/zero of=/var/swap.1 bs=1M count=1024 |