摘要:
import os import random import numpy as np import matplotlib.pyplot as plt from PIL import Image, ImageDraw, ImageFont import torch import torch.nn as 阅读全文
摘要:
import torch import torch.nn as nn import torch.optim as optim from torch.utils.data import DataLoader from torchvision import datasets, transforms im 阅读全文
摘要:
import random import matplotlib.pyplot as plt from collections import defaultdict class TableTennisGame: def init(self, player1, player2, win_games=4) 阅读全文
摘要:
import jieba import re from collections import Counter 读取《西游记》文本文件 def read_file(file_path): with open(file_path, 'r', encoding='utf-8') as file: retu 阅读全文
摘要:
田字格输出 n = eval(input('请输入一个奇数:')) a,b,c,d = '-','+','|',' ' m = n//2 if n%2 == 1: for i in range(n): if i in [0,m,n-1]: print('{0}{1}{0}{1}{0}'.format 阅读全文