mirror of
https://github.com/vlang/v.git
synced 2023-08-10 21:13:21 +03:00
all: change f mut Foo to mut f Foo
This commit is contained in:
@@ -18,7 +18,7 @@ fn evala(i, j int) int {
|
||||
return ((i + j) * (i + j + 1) / 2 + i + 1)
|
||||
}
|
||||
|
||||
fn times(v mut []f64, u []f64) {
|
||||
fn times(mut v []f64, u []f64) {
|
||||
for i in 0..v.len {
|
||||
mut a := f64(0)
|
||||
for j in 0..u.len {
|
||||
@@ -28,7 +28,7 @@ fn times(v mut []f64, u []f64) {
|
||||
}
|
||||
}
|
||||
|
||||
fn times_trans(v mut []f64, u []f64) {
|
||||
fn times_trans(mut v []f64, u []f64) {
|
||||
for i in 0..v.len {
|
||||
mut a := f64(0)
|
||||
for j in 0..u.len {
|
||||
@@ -38,7 +38,7 @@ fn times_trans(v mut []f64, u []f64) {
|
||||
}
|
||||
}
|
||||
|
||||
fn a_times_transp(v mut []f64, u []f64) {
|
||||
fn a_times_transp(mut v []f64, u []f64) {
|
||||
mut x := []f64{len:u.len, init:0}
|
||||
times(mut x, u)
|
||||
times_trans(mut v, x)
|
||||
@@ -69,4 +69,3 @@ fn main() {
|
||||
ans := math.sqrt(vbv / vv)
|
||||
println('${ans:0.9f}')
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user