- CSVファイルを読む
- SKU ID, 商品名, アクセス数
- 壊れてる行を取り除く
- アクセス数(3カラム目)の平均を出力する
- 外れ値を取り除く(最大値と最小値)
- アクセス数(3カラム目) が平均を超える行をすべて出力する
やっとむ(安井力)の連絡先、SNSなどのリンクをまとめています。おおむね、利用頻度順に並んでいます(上の方が高頻度)。
- メール tsutomu.yasui@gmail.com
- メールその2 yattom@yattom.jp
- Facebook https://www.facebook.com/yattom
- Twitter https://twitter.com/yattom
- Mastodon https://mstdn.jp/@yattom
- GitHub https://github.com/yattom/
- Instagram https://www.instagram.com/yattom/
- Discord https://discordapp.com/users/yattom#0620
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
function ColumnKey($idx) | |
{ | |
$excel = New-Object -ComObject Excel.Application | |
$excel.Visible = $true | |
$book = $excel.Workbooks.Add() | |
$sheet = $book.Sheets(1) | |
$cell = $sheet.Cells(1, 1) | |
$col = $idx + 1 | |
$cell.Formula = "=ADDRESS(1,$($col),4)" | |
$text = $cell.Text |
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
[print(("Fizz" if i%3==0 else "") + ("Buzz" if i%5 == 0 else "") or str(i)) for i in range(1,101)] | |
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
def dice_dist(n): | |
d = [0] | |
for i in range(n): | |
d = [b + r for b in d for r in range(1, 7)] | |
for r, c in {n: d.count(n) for n in d}.items(): | |
print(f"{r:>3} {c/6**n:>5.1%} {'*'*c}") |
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
[ec2-user@ip-172-30-0-209 ~]$ mkdir foo | |
[ec2-user@ip-172-30-0-209 ~]$ cd foo | |
[ec2-user@ip-172-30-0-209 foo]$ python3 -m venv . | |
[ec2-user@ip-172-30-0-209 foo]$ . bin/activate | |
(foo) [ec2-user@ip-172-30-0-209 foo]$ pip install pytest-testmon | |
Collecting pytest-testmon | |
Downloading https://files.pythonhosted.org/packages/04/71/0f7ff7772cfd96b5ac1627d1218e2568ce2a2cb6d40b8c7dede4f25d262a/pytest-testmon-0.9.11.tar.gz | |
Collecting pytest<4,>=2.8.0 (from pytest-testmon) | |
Downloading https://files.pythonhosted.org/packages/d3/75/e79b66c9fe6166a90004bb8fb02bab06213c3348e93f3be41d7eaf625554/pytest-3.6.1-py2.py3-none-any.whl (194kB) | |
100% |████████████████████████████████| 194kB 4.0MB/s |
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
<?php | |
declare(strict_types=1); | |
final class FizzBuzz | |
{ | |
public function translate($num) { | |
if ( $num % 15 == 14 ) { | |
return "FizzBuzz"; | |
} | |
if ( $num % 3 == 0 && $num != 72) { |
NewerOlder