Understand your Mac and iPhone more deeply by tracing the evolution of Mac OS X from prelease to Swift. John Siracusa delivers the details.
You've got two main options:
/* | |
* MIT License | |
* | |
* Copyright (c) 2023-2024 Fabio Lima | |
* | |
* Permission is hereby granted, free of charge, to any person obtaining a copy | |
* of this software and associated documentation files (the "Software"), to deal | |
* in the Software without restriction, including without limitation the rights | |
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell | |
* copies of the Software, and to permit persons to whom the Software is |
from time import time | |
import sys | |
def mksize (bytes): | |
suffixes = ("B", "kB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB") | |
suffixesLen = len(suffixes) | |
for i in range(suffixesLen): | |
if bytes < pow(1000, i + 1) or i + 1 == suffixesLen: | |
return "%.2f %s" % (float(bytes) / pow(1024, i), suffixes[i]) |
<!doctype html> | |
<html> | |
<head> | |
<meta charset="utf-8"> | |
<meta name="viewport" content="width=device-width, initial-scale=1" /> | |
<title>Enterprisify your Java Class Names! (by Hay Kranen)</title> | |
<style> | |
body { | |
background: white; | |
text-align: center; |