Toggle navigation shitcode
  • Latest
  • Browse
  • Top
  • Worst
  • Add
  • All 465
  • ActionScript 2
  • Bash 6
  • Brainfuck 1
  • LSL 20
  • C++ 30
  • C# 53
  • CSS 5
  • Pascal 1
  • Django 1
  • Erlang 1
  • GLSL 1
  • Go 7
  • Groovy 1
  • HTML 10
  • Java 73
  • JavaScript 95
  • Less 1
  • Lua 3
  • Nix 1
  • Obj-C 4
  • OCaml 1
  • Perl 1
  • PHP 72
  • PowerShell 1
  • Python 46
  • Ruby 2
  • Rust 1
  • Scala 3
  • SQL 6
  • Swift 4
  • TypeScript 10
  • VBScript 2
#806 Who needs build in functions for converting to GB when you can divide three times? PowerShell -4
$MaxSizeGB = [math]::Round($MaxSize/1024/1024/1024,2)
Write-Output "    the maximum size is $MaxSizeGB GB"

At least [math] is used. So close, and yet so far...

Comments
By Anonymous, 2020-04-03 20:59:34

© Shitcode.net 2023, Powered by Yii Framework

GitHub • About • Admin