参考 Windowsバッチファイル例 ファイル名:gopy.bat(文字コードは、ANSI or Shift-JISで保存) @echo off cls cd C:\Users\各人のユーザフォルダ\Documents\Python date /t echo パイソンを楽しもう... 2020.06.29 参考
Python ブラウザを使わずに天気情報を取得する 準備 pip install beautifulsoup4 スクリプト:getWeather.py # -*- coding: utf-8 -*- import urllib.request from bs4 import Beautifu... 2020.06.26 Python
Python 画像をリサイズする(PythonのPillowを使用) # 画像をリサイズする from PIL import Image img = Image.open("neko_neteru.jpg") # 元の画像ファイル print("元のサイズ {}*{}".format(img.size, im... 2020.06.23 Python
Python Pythonスクリプト演習(2020/6/22) 乱数を使ったスクリプト1 実行イメージ(毎回1~3のどれかの数が表示される) 2 ファイル名:ransu1.py # 乱数を使う1 import random n = random.randint(1, 3) # 1~3の数のどれかが変数n... 2020.06.22 Python
Python 20200612オリジナルスクリプト 習ったことを生かしてPythonスクリプトを作る。条件は10行以上! 順不同で紹介します。 作品1 print("点数で評価を付ける") print("点数は?" ,end="") tensu=int(input()) if tensu >... 2020.06.12 Python
Python 20200611モノクロ写真とスクリプト提出 順不同です 作品1 #好きな数字を入力して計算する print("好きな数字を入力して計算してみましょう!") print("a=",end="") a=int(input()) print("b=",end="") b=int(input... 2020.06.12 Python
Python オリジナルスクリプト20200529提出物 提出1 print("一本250円の鉛筆が5本買うといくらになるか") print("a=",end="") a=input() a=int(a) print("b=",end="") b=input() b=int(b) c=a*b pr... 2020.06.04 Python
Python Pythonスクリプト演習(2020/6/5) 型変換関数を使ったスクリプトサンプル スクリプト1(str) 実行イメージ 日本は47都道府県あります 円周率は3.14です ファイル名:kata_str.py # 型変換関数(str) ken = 47 PI = 3.14 print("... 2020.06.03 Python
Python Pythonスクリプト演習(2020/5/29) キーボードから入力させるスクリプトのサンプルです スクリプト1 実行イメージ お名前は? 涼宮ハルヒ Enter 涼宮ハルヒさん、こんにちは! ファイル名:input_namae.py # キーボードから名前を入力させて表示 print("... 2020.05.28 Python
Python Pythonスクリプト演習(2020/5/22) 2020年5月22日の《プログラミング》授業課題です。 以下の3つのPythonスクリプトを作成・実行確認してください。実行確認後は、GoogleClassroomより提出をしてください。 まだまだプログラムの入力に慣れていないと思います。... 2020.05.21 Python