$33 GRAYBYTE WORDPRESS FILE MANAGER $70

SERVER : vnpttt-amd7f72-h1.vietnix.vn #1 SMP Fri May 24 12:42:50 UTC 2024
SERVER IP : 103.200.23.149 | ADMIN IP 216.73.216.22
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/usr/lib/golang/src/strconv/

HOME
Current File : /usr/lib/golang/src/strconv//ctoa.go
// Copyright 2020 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

package strconv

// FormatComplex converts the complex number c to a string of the
// form (a+bi) where a and b are the real and imaginary parts,
// formatted according to the format fmt and precision prec.
//
// The format fmt and precision prec have the same meaning as in [FormatFloat].
// It rounds the result assuming that the original was obtained from a complex
// value of bitSize bits, which must be 64 for complex64 and 128 for complex128.
func FormatComplex(c complex128, fmt byte, prec, bitSize int) string {
	if bitSize != 64 && bitSize != 128 {
		panic("invalid bitSize")
	}
	bitSize >>= 1 // complex64 uses float32 internally

	// Check if imaginary part has a sign. If not, add one.
	im := FormatFloat(imag(c), fmt, prec, bitSize)
	if im[0] != '+' && im[0] != '-' {
		im = "+" + im
	}

	return "(" + FormatFloat(real(c), fmt, prec, bitSize) + im + "i)"
}

Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
16 Dec 2025 9.30 PM
root / root
0755
atob.go
0.951 KB
4 Dec 2025 6.06 PM
root / root
0644
atoc.go
3.075 KB
4 Dec 2025 6.06 PM
root / root
0644
atof.go
15.849 KB
4 Dec 2025 6.06 PM
root / root
0644
atoi.go
8.291 KB
4 Dec 2025 6.06 PM
root / root
0644
bytealg.go
0.38 KB
4 Dec 2025 6.06 PM
root / root
0644
bytealg_bootstrap.go
0.392 KB
4 Dec 2025 6.06 PM
root / root
0644
ctoa.go
1.007 KB
4 Dec 2025 6.06 PM
root / root
0644
decimal.go
11.034 KB
4 Dec 2025 6.06 PM
root / root
0644
doc.go
1.911 KB
4 Dec 2025 6.06 PM
root / root
0644
eisel_lemire.go
41.392 KB
4 Dec 2025 6.06 PM
root / root
0644
ftoa.go
14.026 KB
4 Dec 2025 6.06 PM
root / root
0644
ftoaryu.go
15.66 KB
4 Dec 2025 6.06 PM
root / root
0644
isprint.go
11.547 KB
4 Dec 2025 6.06 PM
root / root
0644
itoa.go
4.875 KB
4 Dec 2025 6.06 PM
root / root
0644
makeisprint.go
4.287 KB
4 Dec 2025 6.06 PM
root / root
0644
quote.go
16.596 KB
4 Dec 2025 6.06 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME
Static GIF