Skip to content

Instantly share code, notes, and snippets.

person = {'name': 'Phill', 'age': 22}
print('Name: ', person.get('name'))
print('Age: ', person.get('age'))
# value is not provided
print('Salary: ', person.get('salary'))
from ml_performance_monitoring.monitor import wrap_model
import numpy as np
from sklearn.metrics import mean_squared_error
from sklearn.datasets import load_boston
from sklearn.model_selection import train_test_split
import xgboost as xgb
boston_dataset = load_boston()
X, y = (
if __name__ == '__main__':
print_billing_doc()
#Вывод
Name Price Tax
Book 30 3.0
Pen 5 0.5
def calculate_tax(price, tax):
return price * tax
def print_billing_doc():
tax_rate = 0.1
products = [{'name': 'Book', 'price': 30},
{'name': 'Pen', 'price': 5}]
# print billing header
:link {
outline: 1px dotted blue;
background-color: white;
/* The default value of background-color is `transparent`. You need to
specify a different value, otherwise changes on :visited won't apply. */
}
:visited {
outline-color: orange; /* Visited links have an orange outline */
background-color: green; /* Visited links have a green background */
"""Pacman, классическая аркадная игра.
упражнения для повышения навыков
1. Сменить фон.
2. Изменить количество призраков.
3. Измените место запуска pacman.
4. Сделать призраков быстрее/медленнее.
5. Сделать призраков умнее.
"""
<!DOCTYPE html>
<html>
<head>
<meta charset="utf-8">
<title>JS getComputedStyle() Demo</title>
<style type="text/css">
.message {
background-color: #fff3d4;
border: solid 1px #f6b73c;
import itertools
import sys
import time
def spinner(seconds):
"""Show an animated spinner while we sleep."""
symbols = itertools.cycle('-|/')
tend = time.time() + seconds
while time.time() < tend:
# 'r' is carriage return: return cursor to the start of the line.
def pop(self, key: str) -> Any:
"""Delete and return value at key.
Args:
key (str): Key to pop.
Returns:
Any: Popped value.
"""
from helper._get import *
LOGS.info("Starting...")
######## Connect ########
try: