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
import math as m | |
def search_refraction(alfa: float, d: int) -> float: | |
""" | |
This function solve that https://vk.com/@unilecs-anons-43-prelomlenie task | |
""" | |
# Значение преломления пластины | |
n = 1.5 |
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 sequence_string(e, arr): | |
""" | |
This function solve task from https://vk.com/@unilecs-anons-44-posledovatelnost by the string method | |
:param e: string, len which = 1 | |
:param arr: list of string, len which = 1 | |
:return: bool | |
""" | |
# Кол-во символов e | |
n: int = 5 | |
# e * n -> Строка символов `e` из `n` элементов |
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
""" | |
Maximum number from array | |
Task number of 78 Unilecs (https://vk.com/unilecs) | |
This function solve task from https://vk.com/@unilecs-task-77-proveryaem-chislo-na-prostotu-bez-ciklov | |
""" | |
def function(array: list): | |
def biggest(a:int, b:int): | |
a = str(a) | |
b = str(b) |
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 harvester_math(n:int, m:int) -> int: | |
if n <= m: | |
# n - small | |
return 2*(n - 1) | |
else: | |
# m - small |
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
from io import BytesIO | |
import pandas as pd | |
from aiohttp import ClientSession | |
from asyncio import run | |
# https://docs.google.com/spreadsheets/d/1fzRAc7J38i2xLgq3dzJIgnNtcmM3JYbCI7LlmkvIfcc/edit | |
# |----Идентификатор-книги-(spreadsheet_id)----| | |
async def google_sheet_export_dataframe( | |
spreadsheet_id: str, |
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 | |
$value = $_POST["text"]; | |
if (filter_var($value, FILTER_VALIDATE_EMAIL)) { | |
$curl = curl_init(); | |
curl_setopt_array($curl, array( | |
CURLOPT_URL => 'https://notionforms.io/api/forms/emailsvr/answer', | |
CURLOPT_RETURNTRANSFER => true, | |
CURLOPT_ENCODING => '', | |
CURLOPT_MAXREDIRS => 10, |
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
import requests | |
import pandas as pd | |
from io import BytesIO | |
# https://docs.google.com/spreadsheets/d/1fzRAc7J38i2xLgq3dzJIgnNtcmM3JYbCI7LlmkvIfcc/edit | |
# |----Идентификатор-книги-(spreadsheet_id)----| | |
def google_sheet_export_dataframe( | |
spreadsheet_id: str, | |
sheet_name: str |
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
import requests | |
TOKEN_NOTION = "..." | |
uuid = "..." | |
def get_database_by_id( | |
database_id: str, | |
page_size: int = 1000 |
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
import string | |
import requests | |
import zlib | |
import base64 | |
import pathlib | |
maketrans = bytes.maketrans | |
BEFORE = "scale 4000 width" |
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
# Content /opt/libs/all.yaml | |
include: | |
- 'execute_telnet.yaml' | |
- 'scripts_get_ip.yaml' | |
- 'scripts_ping_ip.yaml' | |
# Content /opt/libs/scripts_get_ip.yaml | |
include: | |
- 'execute_telnet.yaml' |
OlderNewer