Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ks 1 4 #174

Open
wants to merge 7 commits into
base: dev
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ bin/

### VS Code ###
.vscode/
.idea/

### Mac OS ###
.DS_Store
2 changes: 1 addition & 1 deletion .idea/misc.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/vcs.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 14 additions & 0 deletions src/main/kotlin/Lessson_1/L4.kt
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
package Lessson_1

fun main() {

val lenght: Long = 40_848_600_000
val age: Byte = 27
val partOfDay: Float = 0.075F
val seconds: Int = 6480

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Для этого значения можно применить тип, который занимает еще меньше места в памяти)

val partOfYear: Double = 2.0547945205479453E-4
val apogee: Int = 327000
//в задаче же указано число 327_000, было бы 327_00, то применялся бы тип Short. Это как я понял, возможно я ошибаюсь

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Для числа 6480 можно применить тип short. С числом 327000 все верно.

После получения аппрува от меня ПРы нужно мержить в мастер. Если ты это сделал, то подлей плиз мастер ветку сюда. Благодаря этому могут убраться лишние изменения из этого ПРа


println("$lenght\n$age\n$partOfDay\n$seconds\n$partOfYear\n$apogee")
}