Skip to content

Instantly share code, notes, and snippets.

View andersonberg's full-sized avatar

Anderson Berg andersonberg

View GitHub Profile
if has("syntax")
syntax on
endif
C:\Pythonize>cd dist
C:\Pythonize\dist>calc.exe
Digite 1 para seno e 2 para cosseno: 1
Entre com um número: 4
-0.756802495308
from distutils.core import setup
import py2exe
setup(console=['calc.py'])
import math
def main():
modelo = raw_input("Digite 1 para seno e 2 para cosseno: ")
n = raw_input("Entre com um número: ")
choice = int(modelo)
num = float(n)
if choice == 1:
print math.sin(num)
user_tweets = []
tweets = api.GetUserTimeline(user, count=30)
for tweet in tweets:
user_tweets.append(tweet.text.encode('utf-8') + '\n')
print user_tweets
user_tweets = api.GetUserTimeline('user')
for tweet in user_tweets:
print tweet.text
tweets = api.GetPublicTimeline()
for tweet in tweets:
print tweet.text
import twitter
api = twitter.Api()
stdin, stdout, stderr = ssh.exec_command('sudo fdisk -l\n')
stdin.write('1234\n')
stdin.flush()
print stdout.readlines()