/
Puzzman
/
basic_programming
Обзор
Документация
Войти
/
Puzzman
/
basic_programming
Код
Запросы
0
Задачи
Вики
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
course_project_2/Lib/Air/Broom/Broom.cpp
20 строк
502 B
Puzzanis
algo homework 1-2 added
28 сен 2024, 10:23
28 сен 2024, 10:23
2108435
Код
Авторство
О чём код?
#include "Broom.h" float Broom::movement(const int& distance) { int interval_count = distance / 1000; float tmp = ((100 - interval_count) / 100.0); float res_distance = distance * tmp; float res_time{ 0.0 }; res_time = res_distance / speed_; last_race_ = res_time; return res_time; } Broom::Broom() { name_ = "�����"; int speed_ =20; } std::string& Broom::get_name() { return name_; } int Broom::get_type() const { return type_; } float Broom::get_last_race() const { return last_race_; };