1.php から Golang に書き換えでの先頭文字の判定
2.PHP
if($row['version_str'][0] === '-') {
...
}
3.Golang
if string([]rune(row.Version_str)[:1]) == `-` {
...
}
1.php から Golang に書き換えでの先頭文字の判定
2.PHP
if($row['version_str'][0] === '-') {
...
}
3.Golang
if string([]rune(row.Version_str)[:1]) == `-` {
...
}