sudo apt install zsh-autosuggestions zsh-syntax-highlighting zsh
| public class Customer { | |
| private Long id; | |
| private String name; | |
| private Integer tier; | |
| public Long getId() { | |
| return id; | |
| } |
| #include <iostream> | |
| #include <string> | |
| #include <functional> | |
| #include <vector> | |
| template<class ArrayType, class ValueType> | |
| void forEach(const ArrayType& arr, std::function<void(const ValueType&)> callback) { | |
| for (auto entry : arr) { | |
| callback(entry); | |
| } |
| from typing import List, Dict | |
| from fastapi import FastAPI | |
| import motor.motor_asyncio | |
| from bson import ObjectId | |
| from pydantic import BaseModel, Field | |
| class PyObjectId(ObjectId): | |
| @classmethod |
| #include <SoftwareSerial.h> | |
| #define MSP_ATTITUDE 108 | |
| SoftwareSerial mspSerial(11, 12); // RX TX | |
| void setup() { | |
| mspSerial.begin(9600); | |
| Serial.begin(9600); | |
| } |
| import numpy as np | |
| from matplotlib import pyplot as plt | |
| plt.rcParams['figure.figsize'] = [10, 5] | |
| x = np.arange(0, 2 * np.pi, 0.1) | |
| y = 5 * np.sin(x) | |
| plt.plot(x, y) | |
| plt.title('test and тест русского') | |
| plt.xlabel('Time, sec') |
| void setup() { | |
| // put your setup code here, to run once: | |
| pinMode(3, OUTPUT); | |
| pinMode(5, OUTPUT); | |
| pinMode(6, OUTPUT); | |
| Serial.begin(115200); | |
| } | |
| void loop() { |
| float sinValue = 0.0f; | |
| void setup() { | |
| // put your setup code here, to run once: | |
| Serial.begin(9600); | |
| } | |
| void loop() { | |
| // put your main code here, to run repeatedly: | |
| float sinValue = 3.3f * sin(0.025f * millis()); | |
| Serial.println(sinValue); |
| #include <SoftwareSerial.h> | |
| SoftwareSerial gsm(10, 11); // RX, TX | |
| SoftwareSerial gps(2, 3); // RX, TX | |
| char response[100]; | |
| void setup() { | |
| pinMode(5, OUTPUT); | |
| digitalWrite(5, LOW); |