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

Lab4,6 #603

Open
wants to merge 9 commits into
base: Gretchenko_Vladislav
Choose a base branch
from
Open

Conversation

information278
Copy link

внесены изменения по комментариям в 4 лабе, выполнена 6

Comment on lines +8 to +29
func Calculate(x float64) float64 {
if math.Abs(x) >= 1 {
return (math.Pow(1.2, x)) - (math.Pow(x, 1.2))
}
return math.Acos(x)
}

func TaskA(Xmin, Xmax, Xdel float64) []float64 {
var y []float64
for x := Xmin; x <= Xmax; x += Xdel {
y = append(y, Calculate(x))
}
return y
}

func TaskB(x [5]float64) []float64 {
var y []float64
for _, value := range x {
y = append(y, Calculate(value))
}
return y
}
Copy link
Collaborator

Choose a reason for hiding this comment

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

Нет смысла делать их публичными, вы используете их только внутри пакета

return y
}

func Runlab4() {
Copy link
Collaborator

Choose a reason for hiding this comment

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

CamelCase соблюдайте во всем проекте

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants