mirror of
https://github.com/andatoshiki/toshiki-notebook.git
synced 2026-06-06 09:16:45 +00:00
49 lines
75 KiB
HTML
49 lines
75 KiB
HTML
<!DOCTYPE html>
|
||
<html lang="en-US" dir="ltr">
|
||
<head>
|
||
<meta charset="utf-8">
|
||
<meta name="viewport" content="width=device-width,initial-scale=1">
|
||
<title>1-1: Values | Toshiki's Note</title>
|
||
<meta name="description" content="Chapter 1-1 notes on values">
|
||
<link rel="preload stylesheet" href="/assets/style.bd240186.css" as="style">
|
||
|
||
<script type="module" src="/assets/app.6020b1dd.js"></script>
|
||
<link rel="preload" href="/assets/inter-roman-latin.2ed14f66.woff2" as="font" type="font/woff2" crossorigin="">
|
||
<link rel="modulepreload" href="/assets/chunks/framework.b7580407.js">
|
||
<link rel="modulepreload" href="/assets/chunks/theme.7de1b093.js">
|
||
<link rel="modulepreload" href="/assets/chunks/commonjsHelpers.725317a4.js">
|
||
<link rel="modulepreload" href="/assets/chunks/PageInfo.vue_vue_type_script_setup_true_lang.250b3e56.js">
|
||
<link rel="modulepreload" href="/assets/javascript_notes_1_1-1.md.37d06ab5.lean.js">
|
||
<link rel="stylesheet" href="https://cdnjs.toshiki.dev/ajax/libs/KaTeX/0.16.0/katex.min.css">
|
||
<link rel="stylesheet" href="https://cdnjs.toshiki.dev/ajax/libs/font-awesome/6.3.0/css/all.min.css">
|
||
<link rel="icon" href="https://r2.toshiki.dev/cdn/toshiki-notebook-favicon/favicon.ico">
|
||
<meta name="author" content="Anda Toshiki">
|
||
<meta name="keywords" content="Toshiki, Anda Toshiki, andatoshiki, GitHub, GitHub action, Vitepress, Vite, Notebook, Knowledge base, Programming, Programming Notes, Academic, Personal, Notebook, Productivity, Journal, Note-taking, Markdown, Notepad, Organization, Tutorial">
|
||
<meta name="google-site-verification" content="lm7PNJiYSPEx1dMast1Xptc0Vk0cU06o-daZSsIgr2I">
|
||
<meta name="HandheldFriendly" content="True">
|
||
<meta name="MobileOptimized" content="320">
|
||
<meta name="theme-color" content="#3c8772">
|
||
<meta property="og:type" content="website">
|
||
<meta property="og:locale" content="en-US">
|
||
<meta property="og:title" content="Toshiki's Note">
|
||
<meta property="og:description" content="Toshiki's web notebook served via Vitepress!">
|
||
<meta property="og:site" content="https://note.toshiki.dev">
|
||
<meta property="og:site_name" content="Toshiki's Note">
|
||
<meta property="og:image" content="https://note.toshiki.dev/og-cover.png">
|
||
<script>function siteruntime(){window.setTimeout("siteruntime()",1e3),X=new Date("8/24/2021 10:28:00"),Y=new Date,T=Y.getTime()-X.getTime(),M=24*60*60*1e3,a=T/M,A=Math.floor(a),b=(a-A)*24,B=Math.floor(b),c=(b-B)*60,C=Math.floor((b-B)*60),D=Math.floor((c-C)*60),siteruntime_span.innerHTML="This site has been running for: "+A+" day(s) "+B+" hour(s) "+C+" minute(s) "+D+" second(s)"}siteruntime();</script>
|
||
<script async defer data-website-id="" src=""></script>
|
||
<script id="check-dark-mode">(()=>{const e=localStorage.getItem("vitepress-theme-appearance")||"auto",a=window.matchMedia("(prefers-color-scheme: dark)").matches;(!e||e==="auto"?a:e==="dark")&&document.documentElement.classList.add("dark")})();</script>
|
||
<script id="check-mac-os">document.documentElement.classList.toggle("mac",/Mac|iPhone|iPod|iPad/i.test(navigator.platform));</script>
|
||
</head>
|
||
<body>
|
||
<div id="app"><div class="Layout" data-v-bb676018><!--[--><!--]--><!--[--><span tabindex="-1" data-v-197f0fa6></span><a href="#VPContent" class="VPSkipLink visually-hidden" data-v-197f0fa6> Skip to content </a><!--]--><!----><header class="VPNav" data-v-bb676018 data-v-f92d2e4c><div class="VPNavBar has-sidebar" data-v-f92d2e4c data-v-e4fc9f8b><div class="container" data-v-e4fc9f8b><div class="title" data-v-e4fc9f8b><div class="VPNavBarTitle has-sidebar" data-v-e4fc9f8b data-v-d919d4a8><a class="title" href="/" data-v-d919d4a8><!--[--><!--]--><!--[--><img class="VPImage logo" src="/logos/logo.png" alt data-v-26d78c9a><!--]--><!--[-->Toshiki's Note<!--]--><!--[--><!--]--></a></div></div><div class="content" data-v-e4fc9f8b><div class="curtain" data-v-e4fc9f8b></div><div class="content-body" data-v-e4fc9f8b><!--[--><!--]--><div class="VPNavBarSearch search" data-v-e4fc9f8b><!--[--><!----><div id="docsearch"><button type="button" class="DocSearch DocSearch-Button" aria-label="Search"><span class="DocSearch-Button-Container"><svg class="DocSearch-Search-Icon" width="20" height="20" viewBox="0 0 20 20" aria-label="search icon"><path d="M14.386 14.386l4.0877 4.0877-4.0877-4.0877c-2.9418 2.9419-7.7115 2.9419-10.6533 0-2.9419-2.9418-2.9419-7.7115 0-10.6533 2.9418-2.9419 7.7115-2.9419 10.6533 0 2.9419 2.9418 2.9419 7.7115 0 10.6533z" stroke="currentColor" fill="none" fill-rule="evenodd" stroke-linecap="round" stroke-linejoin="round"></path></svg><span class="DocSearch-Button-Placeholder">Search</span></span><span class="DocSearch-Button-Keys"><kbd class="DocSearch-Button-Key"></kbd><kbd class="DocSearch-Button-Key">K</kbd></span></button></div><!--]--></div><nav aria-labelledby="main-nav-aria-label" class="VPNavBarMenu menu" data-v-e4fc9f8b data-v-368cfbc9><span id="main-nav-aria-label" class="visually-hidden" data-v-368cfbc9>Main Navigation</span><!--[--><!--[--><a class="VPLink link VPNavBarMenuLink" href="/development/" tabindex="0" data-v-368cfbc9 data-v-0eb8cc79><!--[--><span data-v-0eb8cc79>Development</span><!--]--></a><!--]--><!--[--><div class="VPFlyout VPNavBarMenuGroup active" data-v-368cfbc9 data-v-419e6f76><button type="button" class="button" aria-haspopup="true" aria-expanded="false" data-v-419e6f76><span class="text" data-v-419e6f76><!----><span data-v-419e6f76>Academic</span><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="text-icon" data-v-419e6f76><path d="M12,16c-0.3,0-0.5-0.1-0.7-0.3l-6-6c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l5.3,5.3l5.3-5.3c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-6,6C12.5,15.9,12.3,16,12,16z"></path></svg></span></button><div class="menu" data-v-419e6f76><div class="VPMenu" data-v-419e6f76 data-v-3795579e><div class="items" data-v-3795579e><!--[--><!--[--><div class="VPMenuGroup" data-v-3795579e data-v-bdc27f57><p class="title" data-v-bdc27f57>K-12</p><!--[--><!--[--><div class="VPMenuLink" data-v-bdc27f57 data-v-df1d8bd6><a class="VPLink link" href="/academic/chemistry/index" data-v-df1d8bd6><!--[-->Chemistry<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-bdc27f57 data-v-df1d8bd6><a class="VPLink link" href="/discrete-math/index" data-v-df1d8bd6><!--[-->Discrete Math.<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-bdc27f57 data-v-df1d8bd6><a class="VPLink link" href="/academic/literature/index" data-v-df1d8bd6><!--[-->Literature<!--]--></a></div><!--]--><!--]--></div><!--]--><!--[--><div class="VPMenuGroup" data-v-3795579e data-v-bdc27f57><p class="title" data-v-bdc27f57>Tools</p><!--[--><!--[--><div class="VPMenuLink" data-v-bdc27f57 data-v-df1d8bd6><a class="VPLink link" href="/academic/physics/ipho-formulas-jpn/1" data-v-df1d8bd6><!--[-->Formulas for IPhO JPN.<!--]--></a></div><!--]--><!--]--></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><span class="VPLink" data-v-df1d8bd6><!--[--><!--]--></span></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><span class="VPLink" data-v-df1d8bd6><!--[--><!--]--></span></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><span class="VPLink" data-v-df1d8bd6><!--[--><!--]--></span></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><span class="VPLink" data-v-df1d8bd6><!--[--><!--]--></span></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><span class="VPLink" data-v-df1d8bd6><!--[--><!--]--></span></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><span class="VPLink" data-v-df1d8bd6><!--[--><!--]--></span></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><span class="VPLink" data-v-df1d8bd6><!--[--><!--]--></span></div><!--]--><!--]--></div><!--[--><!--]--></div></div></div><!--]--><!--[--><div class="VPFlyout VPNavBarMenuGroup" data-v-368cfbc9 data-v-419e6f76><button type="button" class="button" aria-haspopup="true" aria-expanded="false" data-v-419e6f76><span class="text" data-v-419e6f76><!----><span data-v-419e6f76>Application</span><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="text-icon" data-v-419e6f76><path d="M12,16c-0.3,0-0.5-0.1-0.7-0.3l-6-6c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l5.3,5.3l5.3-5.3c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-6,6C12.5,15.9,12.3,16,12,16z"></path></svg></span></button><div class="menu" data-v-419e6f76><div class="VPMenu" data-v-419e6f76 data-v-3795579e><div class="items" data-v-3795579e><!--[--><!--[--><div class="VPMenuGroup" data-v-3795579e data-v-bdc27f57><p class="title" data-v-bdc27f57>Personal projects</p><!--[--><!--[--><div class="VPMenuLink" data-v-bdc27f57 data-v-df1d8bd6><a class="VPLink link" href="/application/markdown-it-katex/how-to-use" data-v-df1d8bd6><!--[-->markdown-it-katex<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-bdc27f57 data-v-df1d8bd6><a class="VPLink link" href="/application/vitepress-plugin-shiki-twoslash/index" data-v-df1d8bd6><!--[-->vitepress-plugin-shiki-twoslash<!--]--></a></div><!--]--><!--]--></div><!--]--><!--]--></div><!--[--><!--]--></div></div></div><!--]--><!--[--><div class="VPFlyout VPNavBarMenuGroup" data-v-368cfbc9 data-v-419e6f76><button type="button" class="button" aria-haspopup="true" aria-expanded="false" data-v-419e6f76><span class="text" data-v-419e6f76><!----><span data-v-419e6f76>Save</span><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="text-icon" data-v-419e6f76><path d="M12,16c-0.3,0-0.5-0.1-0.7-0.3l-6-6c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l5.3,5.3l5.3-5.3c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-6,6C12.5,15.9,12.3,16,12,16z"></path></svg></span></button><div class="menu" data-v-419e6f76><div class="VPMenu" data-v-419e6f76 data-v-3795579e><div class="items" data-v-3795579e><!--[--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><a class="VPLink link" href="/save/reading/index" data-v-df1d8bd6><!--[-->Reading<!--]--></a></div><!--]--><!--[--><div class="VPMenuLink" data-v-3795579e data-v-df1d8bd6><a class="VPLink link" href="/academic/vocabulary/index" data-v-df1d8bd6><!--[-->Vocabulary<!--]--></a></div><!--]--><!--]--></div><!--[--><!--]--></div></div></div><!--]--><!--]--></nav><!----><div class="VPNavBarAppearance appearance" data-v-e4fc9f8b data-v-82003167><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="toggle dark mode" aria-checked="false" data-v-82003167 data-v-f31c77b6 data-v-ad8fa6cf><span class="check" data-v-ad8fa6cf><span class="icon" data-v-ad8fa6cf><!--[--><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="sun" data-v-f31c77b6><path d="M12,18c-3.3,0-6-2.7-6-6s2.7-6,6-6s6,2.7,6,6S15.3,18,12,18zM12,8c-2.2,0-4,1.8-4,4c0,2.2,1.8,4,4,4c2.2,0,4-1.8,4-4C16,9.8,14.2,8,12,8z"></path><path d="M12,4c-0.6,0-1-0.4-1-1V1c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,3.6,12.6,4,12,4z"></path><path d="M12,24c-0.6,0-1-0.4-1-1v-2c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,23.6,12.6,24,12,24z"></path><path d="M5.6,6.6c-0.3,0-0.5-0.1-0.7-0.3L3.5,4.9c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C6.2,6.5,5.9,6.6,5.6,6.6z"></path><path d="M19.8,20.8c-0.3,0-0.5-0.1-0.7-0.3l-1.4-1.4c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C20.3,20.7,20,20.8,19.8,20.8z"></path><path d="M3,13H1c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S3.6,13,3,13z"></path><path d="M23,13h-2c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S23.6,13,23,13z"></path><path d="M4.2,20.8c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C4.7,20.7,4.5,20.8,4.2,20.8z"></path><path d="M18.4,6.6c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C18.9,6.5,18.6,6.6,18.4,6.6z"></path></svg><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="moon" data-v-f31c77b6><path d="M12.1,22c-0.3,0-0.6,0-0.9,0c-5.5-0.5-9.5-5.4-9-10.9c0.4-4.8,4.2-8.6,9-9c0.4,0,0.8,0.2,1,0.5c0.2,0.3,0.2,0.8-0.1,1.1c-2,2.7-1.4,6.4,1.3,8.4c2.1,1.6,5,1.6,7.1,0c0.3-0.2,0.7-0.3,1.1-0.1c0.3,0.2,0.5,0.6,0.5,1c-0.2,2.7-1.5,5.1-3.6,6.8C16.6,21.2,14.4,22,12.1,22zM9.3,4.4c-2.9,1-5,3.6-5.2,6.8c-0.4,4.4,2.8,8.3,7.2,8.7c2.1,0.2,4.2-0.4,5.8-1.8c1.1-0.9,1.9-2.1,2.4-3.4c-2.5,0.9-5.3,0.5-7.5-1.1C9.2,11.4,8.1,7.7,9.3,4.4z"></path></svg><!--]--></span></span></button></div><div class="VPSocialLinks VPNavBarSocialLinks social-links" data-v-e4fc9f8b data-v-3c6c0985 data-v-aea42604><!--[--><a class="VPSocialLink no-icon" href="https://github.com/andatoshiki" aria-label="github" target="_blank" rel="noopener" data-v-aea42604 data-v-d53a05fb><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitHub</title><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg></a><a class="VPSocialLink no-icon" href="https://twitter.com/andatoshiki" aria-label="twitter" target="_blank" rel="noopener" data-v-aea42604 data-v-d53a05fb><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Twitter</title><path d="M21.543 7.104c.015.211.015.423.015.636 0 6.507-4.954 14.01-14.01 14.01v-.003A13.94 13.94 0 0 1 0 19.539a9.88 9.88 0 0 0 7.287-2.041 4.93 4.93 0 0 1-4.6-3.42 4.916 4.916 0 0 0 2.223-.084A4.926 4.926 0 0 1 .96 9.167v-.062a4.887 4.887 0 0 0 2.235.616A4.928 4.928 0 0 1 1.67 3.148 13.98 13.98 0 0 0 11.82 8.292a4.929 4.929 0 0 1 8.39-4.49 9.868 9.868 0 0 0 3.128-1.196 4.941 4.941 0 0 1-2.165 2.724A9.828 9.828 0 0 0 24 4.555a10.019 10.019 0 0 1-2.457 2.549z"/></svg></a><!--]--></div><div class="VPFlyout VPNavBarExtra extra" data-v-e4fc9f8b data-v-edb32f2a data-v-419e6f76><button type="button" class="button" aria-haspopup="true" aria-expanded="false" aria-label="extra navigation" data-v-419e6f76><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="icon" data-v-419e6f76><circle cx="12" cy="12" r="2"></circle><circle cx="19" cy="12" r="2"></circle><circle cx="5" cy="12" r="2"></circle></svg></button><div class="menu" data-v-419e6f76><div class="VPMenu" data-v-419e6f76 data-v-3795579e><!----><!--[--><!--[--><!----><div class="group" data-v-edb32f2a><div class="item appearance" data-v-edb32f2a><p class="label" data-v-edb32f2a>Appearance</p><div class="appearance-action" data-v-edb32f2a><button class="VPSwitch VPSwitchAppearance" type="button" role="switch" title="toggle dark mode" aria-checked="false" data-v-edb32f2a data-v-f31c77b6 data-v-ad8fa6cf><span class="check" data-v-ad8fa6cf><span class="icon" data-v-ad8fa6cf><!--[--><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="sun" data-v-f31c77b6><path d="M12,18c-3.3,0-6-2.7-6-6s2.7-6,6-6s6,2.7,6,6S15.3,18,12,18zM12,8c-2.2,0-4,1.8-4,4c0,2.2,1.8,4,4,4c2.2,0,4-1.8,4-4C16,9.8,14.2,8,12,8z"></path><path d="M12,4c-0.6,0-1-0.4-1-1V1c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,3.6,12.6,4,12,4z"></path><path d="M12,24c-0.6,0-1-0.4-1-1v-2c0-0.6,0.4-1,1-1s1,0.4,1,1v2C13,23.6,12.6,24,12,24z"></path><path d="M5.6,6.6c-0.3,0-0.5-0.1-0.7-0.3L3.5,4.9c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C6.2,6.5,5.9,6.6,5.6,6.6z"></path><path d="M19.8,20.8c-0.3,0-0.5-0.1-0.7-0.3l-1.4-1.4c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l1.4,1.4c0.4,0.4,0.4,1,0,1.4C20.3,20.7,20,20.8,19.8,20.8z"></path><path d="M3,13H1c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S3.6,13,3,13z"></path><path d="M23,13h-2c-0.6,0-1-0.4-1-1s0.4-1,1-1h2c0.6,0,1,0.4,1,1S23.6,13,23,13z"></path><path d="M4.2,20.8c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C4.7,20.7,4.5,20.8,4.2,20.8z"></path><path d="M18.4,6.6c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l1.4-1.4c0.4-0.4,1-0.4,1.4,0s0.4,1,0,1.4l-1.4,1.4C18.9,6.5,18.6,6.6,18.4,6.6z"></path></svg><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="moon" data-v-f31c77b6><path d="M12.1,22c-0.3,0-0.6,0-0.9,0c-5.5-0.5-9.5-5.4-9-10.9c0.4-4.8,4.2-8.6,9-9c0.4,0,0.8,0.2,1,0.5c0.2,0.3,0.2,0.8-0.1,1.1c-2,2.7-1.4,6.4,1.3,8.4c2.1,1.6,5,1.6,7.1,0c0.3-0.2,0.7-0.3,1.1-0.1c0.3,0.2,0.5,0.6,0.5,1c-0.2,2.7-1.5,5.1-3.6,6.8C16.6,21.2,14.4,22,12.1,22zM9.3,4.4c-2.9,1-5,3.6-5.2,6.8c-0.4,4.4,2.8,8.3,7.2,8.7c2.1,0.2,4.2-0.4,5.8-1.8c1.1-0.9,1.9-2.1,2.4-3.4c-2.5,0.9-5.3,0.5-7.5-1.1C9.2,11.4,8.1,7.7,9.3,4.4z"></path></svg><!--]--></span></span></button></div></div></div><div class="group" data-v-edb32f2a><div class="item social-links" data-v-edb32f2a><div class="VPSocialLinks social-links-list" data-v-edb32f2a data-v-aea42604><!--[--><a class="VPSocialLink no-icon" href="https://github.com/andatoshiki" aria-label="github" target="_blank" rel="noopener" data-v-aea42604 data-v-d53a05fb><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>GitHub</title><path d="M12 .297c-6.63 0-12 5.373-12 12 0 5.303 3.438 9.8 8.205 11.385.6.113.82-.258.82-.577 0-.285-.01-1.04-.015-2.04-3.338.724-4.042-1.61-4.042-1.61C4.422 18.07 3.633 17.7 3.633 17.7c-1.087-.744.084-.729.084-.729 1.205.084 1.838 1.236 1.838 1.236 1.07 1.835 2.809 1.305 3.495.998.108-.776.417-1.305.76-1.605-2.665-.3-5.466-1.332-5.466-5.93 0-1.31.465-2.38 1.235-3.22-.135-.303-.54-1.523.105-3.176 0 0 1.005-.322 3.3 1.23.96-.267 1.98-.399 3-.405 1.02.006 2.04.138 3 .405 2.28-1.552 3.285-1.23 3.285-1.23.645 1.653.24 2.873.12 3.176.765.84 1.23 1.91 1.23 3.22 0 4.61-2.805 5.625-5.475 5.92.42.36.81 1.096.81 2.22 0 1.606-.015 2.896-.015 3.286 0 .315.21.69.825.57C20.565 22.092 24 17.592 24 12.297c0-6.627-5.373-12-12-12"/></svg></a><a class="VPSocialLink no-icon" href="https://twitter.com/andatoshiki" aria-label="twitter" target="_blank" rel="noopener" data-v-aea42604 data-v-d53a05fb><svg role="img" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg"><title>Twitter</title><path d="M21.543 7.104c.015.211.015.423.015.636 0 6.507-4.954 14.01-14.01 14.01v-.003A13.94 13.94 0 0 1 0 19.539a9.88 9.88 0 0 0 7.287-2.041 4.93 4.93 0 0 1-4.6-3.42 4.916 4.916 0 0 0 2.223-.084A4.926 4.926 0 0 1 .96 9.167v-.062a4.887 4.887 0 0 0 2.235.616A4.928 4.928 0 0 1 1.67 3.148 13.98 13.98 0 0 0 11.82 8.292a4.929 4.929 0 0 1 8.39-4.49 9.868 9.868 0 0 0 3.128-1.196 4.941 4.941 0 0 1-2.165 2.724A9.828 9.828 0 0 0 24 4.555a10.019 10.019 0 0 1-2.457 2.549z"/></svg></a><!--]--></div></div></div><!--]--><!--]--></div></div></div><!--[--><!--]--><button type="button" class="VPNavBarHamburger hamburger" aria-label="mobile navigation" aria-expanded="false" aria-controls="VPNavScreen" data-v-e4fc9f8b data-v-305e35d4><span class="container" data-v-305e35d4><span class="top" data-v-305e35d4></span><span class="middle" data-v-305e35d4></span><span class="bottom" data-v-305e35d4></span></span></button></div></div></div></div><!----></header><div class="VPLocalNav reached-top" data-v-bb676018 data-v-6e4e13c1><button class="menu" aria-expanded="false" aria-controls="VPSidebarNav" data-v-6e4e13c1><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="menu-icon" data-v-6e4e13c1><path d="M17,11H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h14c0.6,0,1,0.4,1,1S17.6,11,17,11z"></path><path d="M21,7H3C2.4,7,2,6.6,2,6s0.4-1,1-1h18c0.6,0,1,0.4,1,1S21.6,7,21,7z"></path><path d="M21,15H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h18c0.6,0,1,0.4,1,1S21.6,15,21,15z"></path><path d="M17,19H3c-0.6,0-1-0.4-1-1s0.4-1,1-1h14c0.6,0,1,0.4,1,1S17.6,19,17,19z"></path></svg><span class="menu-text" data-v-6e4e13c1>Menu</span></button><div class="VPLocalNavOutlineDropdown" style="--vp-vh:0px;" data-v-6e4e13c1 data-v-55e6f1d6><button data-v-55e6f1d6>Return to top</button><!----></div></div><aside class="VPSidebar" data-v-bb676018 data-v-9b5436d7><div class="curtain" data-v-9b5436d7></div><nav class="nav" id="VPSidebarNav" aria-labelledby="sidebar-aria-label" tabindex="-1" data-v-9b5436d7><span class="visually-hidden" id="sidebar-aria-label" data-v-9b5436d7> Sidebar Navigation </span><!--[--><!--]--><!--[--><div class="group" data-v-9b5436d7><section class="VPSidebarItem level-0 collapsible has-active" data-v-9b5436d7 data-v-c543663c><div class="item" role="button" tabindex="0" data-v-c543663c><div class="indicator" data-v-c543663c></div><h2 class="text" data-v-c543663c>1: Basic JavaScript-Value, Variables, and Control Flow</h2><div class="caret" role="button" aria-label="toggle section" tabindex="0" data-v-c543663c><svg xmlns="http://www.w3.org/2000/svg" aria-hidden="true" focusable="false" viewbox="0 0 24 24" class="caret-icon" data-v-c543663c><path d="M9,19c-0.3,0-0.5-0.1-0.7-0.3c-0.4-0.4-0.4-1,0-1.4l5.3-5.3L8.3,6.7c-0.4-0.4-0.4-1,0-1.4s1-0.4,1.4,0l6,6c0.4,0.4,0.4,1,0,1.4l-6,6C9.5,18.9,9.3,19,9,19z"></path></svg></div></div><div class="items" data-v-c543663c><!--[--><div class="VPSidebarItem level-1 is-link" data-v-c543663c data-v-c543663c><div class="item" data-v-c543663c><div class="indicator" data-v-c543663c></div><a class="VPLink link link" href="/javascript/notes/1/1-1" data-v-c543663c><!--[--><p class="text" data-v-c543663c>1-1: Numbers</p><!--]--></a><!----></div><!----></div><div class="VPSidebarItem level-1" data-v-c543663c data-v-c543663c><!----><!----></div><div class="VPSidebarItem level-1" data-v-c543663c data-v-c543663c><!----><!----></div><div class="VPSidebarItem level-1" data-v-c543663c data-v-c543663c><!----><!----></div><div class="VPSidebarItem level-1" data-v-c543663c data-v-c543663c><!----><!----></div><!--]--></div></section></div><!--]--><!--[--><!--]--></nav></aside><div class="VPContent has-sidebar" id="VPContent" data-v-bb676018 data-v-7787f055><div class="VPDoc has-sidebar has-aside" data-v-7787f055 data-v-eb54b406><!--[--><!--]--><div class="container" data-v-eb54b406><div class="aside" data-v-eb54b406><div class="aside-curtain" data-v-eb54b406></div><div class="aside-container" data-v-eb54b406><div class="aside-content" data-v-eb54b406><div class="VPDocAside" data-v-eb54b406 data-v-d3dab3d7><!--[--><!--]--><!--[--><!--]--><div class="VPDocAsideOutline" role="navigation" data-v-d3dab3d7 data-v-98b3e62f><div class="content" data-v-98b3e62f><div class="outline-marker" data-v-98b3e62f></div><div class="outline-title" role="heading" aria-level="2" data-v-98b3e62f>TOC</div><nav aria-labelledby="doc-outline-aria-label" data-v-98b3e62f><span class="visually-hidden" id="doc-outline-aria-label" data-v-98b3e62f> Table of Contents for current page </span><ul class="root" data-v-98b3e62f data-v-1772882b><!--[--><!--]--></ul></nav></div></div><!--[--><!--]--><div class="spacer" data-v-d3dab3d7></div><!--[--><!--]--><!----><!--[--><!--]--><!--[--><!--[--><!--[--><!--[--><div class="VPDocAsideSponsors"><div class="VPSponsors vp-sponsor aside"><!--[--><section class="vp-sponsor-section"><!----><div class="VPSponsorsGrid vp-sponsor-grid medium"><!--[--><div class="vp-sponsor-grid-item"><a class="vp-sponsor-grid-link" target="_blank" rel="sponsored noopener"><article class="vp-sponsor-grid-box"><h4 class="visually-hidden"></h4><img class="vp-sponsor-grid-image" src="https://jsd.toshiki.dev/gh/andatoshiki/toshiki-notebook@master/assets/logo/sponsor/telegram.png"></article></a></div><!--]--></div></section><!--]--></div></div><!--]--><!--]--><!--]--><!--]--></div></div></div></div><div class="content" data-v-eb54b406><div class="content-container" data-v-eb54b406><!--[--><!--]--><!----><main class="main" data-v-eb54b406><div style="position:relative;" class="vp-doc _javascript_notes_1_1-1" data-v-eb54b406><div><h1 id="_1-1-values" tabindex="-1">1-1: Values <a class="header-anchor" href="#_1-1-values" aria-label="Permalink to "1-1: Values""></a></h1><div><section class="border-b-1 border-[var(--vp-c-divider)] w-full border-b-solid mt-[24px] pb-[12px] flex gap-[12px] mb-[12px] flex-wrap max-w-[85%]"><div class="flex gap-[4px] items-center"><svg style="display:inline-block;" viewBox="0 0 16 16" width="1.2em" height="1.2em"><path fill="currentColor" d="M8 16A8 8 0 1 1 8 0a8 8 0 0 1 0 16Zm.847-8.145a2.502 2.502 0 1 0-1.694 0C5.471 8.261 4 9.775 4 11c0 .395.145.995 1 .995h6c.855 0 1-.6 1-.995c0-1.224-1.47-2.74-3.153-3.145Z"></path></svg> Author:<span>Anda Toshiki</span></div><!----><div class="flex gap-[4px] items-center"><svg style="display:inline-block;" viewBox="0 0 15 15" width="1.2em" height="1.2em"><path fill="currentColor" fill-rule="evenodd" d="M1.903 7.297c0 3.044 2.207 5.118 4.686 5.547a.521.521 0 1 1-.178 1.027C3.5 13.367.861 10.913.861 7.297c0-1.537.699-2.745 1.515-3.663c.585-.658 1.254-1.193 1.792-1.602H2.532a.5.5 0 0 1 0-1h3a.5.5 0 0 1 .5.5v3a.5.5 0 0 1-1 0V2.686l-.001.002c-.572.43-1.27.957-1.875 1.638c-.715.804-1.253 1.776-1.253 2.97Zm11.108.406c0-3.012-2.16-5.073-4.607-5.533a.521.521 0 1 1 .192-1.024c2.874.54 5.457 2.98 5.457 6.557c0 1.537-.699 2.744-1.515 3.663c-.585.658-1.254 1.193-1.792 1.602h1.636a.5.5 0 1 1 0 1h-3a.5.5 0 0 1-.5-.5v-3a.5.5 0 1 1 1 0v1.845h.002c.571-.432 1.27-.958 1.874-1.64c.715-.803 1.253-1.775 1.253-2.97Z" clip-rule="evenodd"></path></svg> Updated:<span>2 minutes ago</span></div><div class="flex gap-[4px] items-center"><svg style="display:inline-block;" viewBox="0 0 16 16" width="1.2em" height="1.2em"><path fill="currentColor" d="M9.293 0H4a2 2 0 0 0-2 2v12a2 2 0 0 0 2 2h8a2 2 0 0 0 2-2V4.707A1 1 0 0 0 13.707 4L10 .293A1 1 0 0 0 9.293 0zM9.5 3.5v-2l3 3h-2a1 1 0 0 1-1-1zM5.485 6.879l1.036 4.144l.997-3.655a.5.5 0 0 1 .964 0l.997 3.655l1.036-4.144a.5.5 0 0 1 .97.242l-1.5 6a.5.5 0 0 1-.967.01L8 9.402l-1.018 3.73a.5.5 0 0 1-.967-.01l-1.5-6a.5.5 0 1 1 .97-.242z"></path></svg> Words:<span>1.5k</span></div><div class="flex gap-[4px] items-center"><svg style="display:inline-block;" viewBox="0 0 20 20" width="1.2em" height="1.2em"><path fill="currentColor" d="M10 0a10 10 0 1 0 10 10A10 10 0 0 0 10 0zm2.5 14.5L9 11V4h2v6l3 3z"></path></svg> Reading:<span>9 min</span></div></section></div><h2 id="_1-1-1-numbers" tabindex="-1">1-1-1: Numbers <!----> <a class="header-anchor" href="#_1-1-1-numbers" aria-label="Permalink to "1-1-1: Numbers <Badge type="danger" text="must know" />""></a></h2><p>Values of the <em>number</em> type are numeric values, normally written as follows,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#D33682;">144</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#D33682;">144</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><ul><li><p>Put this into a program, it will cause the number 144 to come into existence inside the computer, with the following bash script, 144 might looks like this in bits,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#D33682;">0100000001100010000000000000000000000000000000000000000000000000</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#D33682;">0100000001100010000000000000000000000000000000000000000000000000</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div></li><li><p>With the following bash script, 144 will be converted into binary values in integer form,</p><div class="language-sh vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">sh</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#268BD2;">ip1</span><span style="color:#859900;">=</span><span style="color:#D33682;">144</span><span style="color:#839496;"> </span><span style="color:#586E75;font-style:italic;"># defines a variable named ip1, with the value of 10</span></span>
|
||
<span class="line"><span style="color:#268BD2;">echo</span><span style="color:#839496;"> </span><span style="color:#2AA198;">"obase=2;</span><span style="color:#268BD2;">$ip1</span><span style="color:#2AA198;">"</span><span style="color:#839496;"> </span><span style="color:#859900;">|</span><span style="color:#839496;"> </span><span style="color:#268BD2;">bc</span><span style="color:#839496;"> </span><span style="color:#586E75;font-style:italic;"># convert the value to binary via bc</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#268BD2;">ip1</span><span style="color:#859900;">=</span><span style="color:#D33682;">144</span><span style="color:#657B83;"> </span><span style="color:#93A1A1;font-style:italic;"># defines a variable named ip1, with the value of 10</span></span>
|
||
<span class="line"><span style="color:#268BD2;">echo</span><span style="color:#657B83;"> </span><span style="color:#2AA198;">"obase=2;</span><span style="color:#268BD2;">$ip1</span><span style="color:#2AA198;">"</span><span style="color:#657B83;"> </span><span style="color:#859900;">|</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">bc</span><span style="color:#657B83;"> </span><span style="color:#93A1A1;font-style:italic;"># convert the value to binary via bc</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br></div></div><ul><li>The variable <code>ip1</code> is assigned the value 144.</li><li>The <code>echo</code> command prints out the string "obase=2;144", where "obase=2;" is an argument for <code>bc</code> that tells it to output the result in base 2 (binary), and "10" is the decimal number we want to convert.</li><li>The output of the <code>echo</code> command is piped (using the <code>|</code> character) to <code>bc</code>, which takes the input "<code>obase=2;144</code>" and interprets it as a command to convert the number 10 to binary.</li><li>Finally, the binary equivalent of 144, which is "10010000", is printed to the terminal.</li></ul></li></ul><div class="tip custom-block"><p class="custom-block-title">TIP</p><p>But the standard describes JavaScript numbers as 64-bit floating-point values, which indicates fractions and exponents are available.</p></div><p>Not all whole numbers <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><mn>1</mn><msup><mn>0</mn><mn>19</mn></msup></mrow><annotation encoding="application/x-tex">10^{19}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.8141em;"></span><span class="mord">1</span><span class="mord"><span class="mord">0</span><span class="msupsub"><span class="vlist-t"><span class="vlist-r"><span class="vlist" style="height:0.8141em;"><span style="top:-3.063em;margin-right:0.05em;"><span class="pstrut" style="height:2.7em;"></span><span class="sizing reset-size6 size3 mtight"><span class="mord mtight"><span class="mord mtight">19</span></span></span></span></span></span></span></span></span></span></span></span> fit in a JavaScript number. There are also negative numbers, so one of the bits has to be used to store the sign of the number.</p><ul><li>11 bits are used to store the position of the decimal dot within the number.</li><li>52 bits, any whole number less than <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><msup><mn>2</mn><mn>52</mn></msup></mrow><annotation encoding="application/x-tex">2^{52}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.8141em;"></span><span class="mord"><span class="mord">2</span><span class="msupsub"><span class="vlist-t"><span class="vlist-r"><span class="vlist" style="height:0.8141em;"><span style="top:-3.063em;margin-right:0.05em;"><span class="pstrut" style="height:2.7em;"></span><span class="sizing reset-size6 size3 mtight"><span class="mord mtight"><span class="mord mtight">52</span></span></span></span></span></span></span></span></span></span></span></span>, which is more than <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><mn>1</mn><msup><mn>0</mn><mn>15</mn></msup></mrow><annotation encoding="application/x-tex">10^{15}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.8141em;"></span><span class="mord">1</span><span class="mord"><span class="mord">0</span><span class="msupsub"><span class="vlist-t"><span class="vlist-r"><span class="vlist" style="height:0.8141em;"><span style="top:-3.063em;margin-right:0.05em;"><span class="pstrut" style="height:2.7em;"></span><span class="sizing reset-size6 size3 mtight"><span class="mord mtight"><span class="mord mtight">15</span></span></span></span></span></span></span></span></span></span></span></span> will safely fit in a JavaScript number, numbers we are using stay well below that.</li></ul><p>Fractional numbers are written by using a dot,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#D33682;">9.81</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#D33682;">9.81</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>For extreme huge or tiny numbers, we can also use "scientific" notion by adding an <code>e</code>, followed by the exponent of the number,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#D33682;">2.998e8</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#D33682;">2.998e8</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>This indicates <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><mn>2.998</mn><mo>×</mo><mn>1</mn><msup><mn>0</mn><mn>8</mn></msup><mo>=</mo><mn>29980000</mn></mrow><annotation encoding="application/x-tex">2.998 \times 10^8 = 29980000</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.7278em;vertical-align:-0.0833em;"></span><span class="mord">2.998</span><span class="mspace" style="margin-right:0.2222em;"></span><span class="mbin">×</span><span class="mspace" style="margin-right:0.2222em;"></span></span><span class="base"><span class="strut" style="height:0.8141em;"></span><span class="mord">1</span><span class="mord"><span class="mord">0</span><span class="msupsub"><span class="vlist-t"><span class="vlist-r"><span class="vlist" style="height:0.8141em;"><span style="top:-3.063em;margin-right:0.05em;"><span class="pstrut" style="height:2.7em;"></span><span class="sizing reset-size6 size3 mtight"><span class="mord mtight">8</span></span></span></span></span></span></span></span><span class="mspace" style="margin-right:0.2778em;"></span><span class="mrel">=</span><span class="mspace" style="margin-right:0.2778em;"></span></span><span class="base"><span class="strut" style="height:0.6444em;"></span><span class="mord">29980000</span></span></span></span>.</p><p>Calculations with whole numbers (referred as <em>integers</em>) that fits into 52 bits are guaranteed to be always precise, but calculation with fraction numbers are generally not.</p><ul><li>Such as <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><mi>π</mi></mrow><annotation encoding="application/x-tex">\pi</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.4306em;"></span><span class="mord mathnormal" style="margin-right:0.03588em;">π</span></span></span></span> cannot be precisely expressed by a finite amount of decimal digits, <strong>thus many numbers lose some precision when only 64 bits are available to store them.</strong></li></ul><details class="details custom-block"><summary>1-1-1: Numbers review</summary><ul><li>64 bits: A 64-bit number is a binary sequence of 64 bits, which can represent <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><msup><mn>2</mn><mn>64</mn></msup></mrow><annotation encoding="application/x-tex">2^{64}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.8141em;"></span><span class="mord"><span class="mord">2</span><span class="msupsub"><span class="vlist-t"><span class="vlist-r"><span class="vlist" style="height:0.8141em;"><span style="top:-3.063em;margin-right:0.05em;"><span class="pstrut" style="height:2.7em;"></span><span class="sizing reset-size6 size3 mtight"><span class="mord mtight"><span class="mord mtight">64</span></span></span></span></span></span></span></span></span></span></span></span> (18,446,744,073,709,551,616) different values. This is commonly used for representing memory addresses and integers with large values in computer systems.</li><li>11 bits: An 11-bit number is a binary sequence of 11 bits, which can represent <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><msup><mn>2</mn><mn>11</mn></msup></mrow><annotation encoding="application/x-tex">2^{11}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.8141em;"></span><span class="mord"><span class="mord">2</span><span class="msupsub"><span class="vlist-t"><span class="vlist-r"><span class="vlist" style="height:0.8141em;"><span style="top:-3.063em;margin-right:0.05em;"><span class="pstrut" style="height:2.7em;"></span><span class="sizing reset-size6 size3 mtight"><span class="mord mtight"><span class="mord mtight">11</span></span></span></span></span></span></span></span></span></span></span></span> (2,048) different values. This is often used in computer systems for encoding small integers, such as color values in images.</li><li>52 bits: A 52-bit number is a binary sequence of 52 bits, which can represent <span class="katex"><span class="katex-mathml"><math xmlns="http://www.w3.org/1998/Math/MathML"><semantics><mrow><msup><mn>2</mn><mn>52</mn></msup></mrow><annotation encoding="application/x-tex">2^{52}</annotation></semantics></math></span><span class="katex-html" aria-hidden="true"><span class="base"><span class="strut" style="height:0.8141em;"></span><span class="mord"><span class="mord">2</span><span class="msupsub"><span class="vlist-t"><span class="vlist-r"><span class="vlist" style="height:0.8141em;"><span style="top:-3.063em;margin-right:0.05em;"><span class="pstrut" style="height:2.7em;"></span><span class="sizing reset-size6 size3 mtight"><span class="mord mtight"><span class="mord mtight">52</span></span></span></span></span></span></span></span></span></span></span></span> (4,503,599,627,370,496) different values. This is often used for representing the significand or mantissa portion of a floating-point number in computer systems.</li></ul></details><h2 id="_1-1-2-arithmetic" tabindex="-1">1-1-2: Arithmetic <a class="header-anchor" href="#_1-1-2-arithmetic" aria-label="Permalink to "1-1-2: Arithmetic""></a></h2><p>The main thing to do with numbers is arithmetic. Arithmetic operations such as addition or multiplication take two number values and produce a new number from them, the following is an example of calculation in JavaScript.</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#D33682;">100</span><span style="color:#839496;"> </span><span style="color:#859900;">+</span><span style="color:#839496;"> </span><span style="color:#D33682;">4</span><span style="color:#839496;"> </span><span style="color:#859900;">*</span><span style="color:#839496;"> </span><span style="color:#D33682;">11</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#D33682;">100</span><span style="color:#657B83;"> </span><span style="color:#859900;">+</span><span style="color:#657B83;"> </span><span style="color:#D33682;">4</span><span style="color:#657B83;"> </span><span style="color:#859900;">*</span><span style="color:#657B83;"> </span><span style="color:#D33682;">11</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><ul><li><p>The <code>+</code> and <code>*</code> symbols are called <em>operators</em>.</p><ul><li><code>+</code> apparently stands for addition while <code>*</code> stands for multiplication.</li></ul></li><li><p>This expression indicates the multiplication takes place first then the adding of 100 comes next as a regard to <a href="https://www.khanacademy.org/math/cc-sixth-grade-math/x0267d782:cc-6th-exponents-and-order-of-operations/cc-6th-order-of-operations/v/more-complicated-order-of-operations-example#:~:text=The%20order%20of%20operations%20is,(from%20left%20to%20right)." target="_blank" rel="noreferrer">PEMDAS</a> rules (Order of Operations).</p></li></ul><p>But we can still overwrite the steps of operation using a parenthesis around the addition,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#839496;">;(</span><span style="color:#D33682;">100</span><span style="color:#839496;"> </span><span style="color:#859900;">+</span><span style="color:#839496;"> </span><span style="color:#D33682;">4</span><span style="color:#839496;">) </span><span style="color:#859900;">*</span><span style="color:#839496;"> </span><span style="color:#D33682;">11</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#657B83;">;(</span><span style="color:#D33682;">100</span><span style="color:#657B83;"> </span><span style="color:#859900;">+</span><span style="color:#657B83;"> </span><span style="color:#D33682;">4</span><span style="color:#657B83;">) </span><span style="color:#859900;">*</span><span style="color:#657B83;"> </span><span style="color:#D33682;">11</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>For subtraction, there is the <code>-</code> operator, and division can be done with <code>/</code>. When operators appear together without parentheses, they are applied is determined by the <em>precedence</em> of the operators.</p><ul><li>When multiple operators with the same precedence appear next to each other (as <code>1-2+1</code>), they are applied left to right (refers to PEMDAS).</li><li>Precedence: Priorities.</li></ul><div class="warning custom-block"><p class="custom-block-title">WARNING</p><p>When is doubt, don't care about precedence, just add parentheses for order of operation.</p></div><p>There is one more arithmetic operator, which is the <code>%</code> percent sign used to represent the <em>modulo</em> operation. <strong>The term "X modulo Y" is defined as the remainder of dividing X by Y.</strong></p><ul><li>For example, <code>314 % 100</code> is <code>14</code>, <code>10 % 3</code> is <code>1</code>, and <code>144 % 12</code> is 0 because there are no remainders.</li><li>Modulo's precedence is the same as that of multiplication and division.</li></ul><details class="details custom-block"><summary>1-2: Arithmetic review</summary><ul><li>All of the operators in JavaScript follows precedence rules, or referred as PEMDAS in conventional math. <ul><li><code>+</code> and <code>-</code> has the same lowest precedence.</li><li><code>*</code> , <code>/</code> and <code>%</code> has the same medium precedence.</li><li><code>()</code> has the highest precedence, followed on with brackets.</li></ul></li><li>The symbol <code>%</code> refers to "modulo", in mathematical reading, we say "X modulo Y" is the remainder of X over Y.</li></ul></details><h2 id="_1-1-3-strings" tabindex="-1">1-1-3: Strings <a class="header-anchor" href="#_1-1-3-strings" aria-label="Permalink to "1-1-3: Strings""></a></h2><p>The next data type is the <em>string</em>. Its use is not as evident from its name as with numbers, it also fulfills a very basic role.</p><ul><li>Strings are used to represent text.</li><li>Strings are usually written by enclosing the contents with quotes.</li></ul><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#2AA198;">'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'</span></span>
|
||
<span class="line"><span style="color:#2AA198;">'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#2AA198;">'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'</span></span>
|
||
<span class="line"><span style="color:#2AA198;">'Lorem ipsum dolor sit amet, consectetur adipiscing elit.'</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br></div></div><div class="tip custom-block"><p class="custom-block-title">TIP</p><p><strong>Both single and double quotes</strong> can be used to mark strings</p><ul><li>As long as the quotes at the start and the end of the string match.</li></ul></div><p>Almost anything can be put between quotes, and JavaScript will make a string value out of it. But the followings are tricky to be put between quotes.</p><ul><li><strong>Newlines</strong>: The things we get when we press <kbd>enter</kbd> on keyboard. We uses <code>\n</code> to represent.</li><li><strong>New tab</strong>: Similarly like newlines, <code>\t</code> indicates a new tab being indented.</li></ul><p>Take the following string as an example,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#2AA198;">'Lorem ipsum dolor sit amet,</span><span style="color:#CB4B16;">\n</span><span style="color:#2AA198;"> consectetur adipiscing elit.'</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#2AA198;">'Lorem ipsum dolor sit amet,</span><span style="color:#CB4B16;">\n</span><span style="color:#2AA198;"> consectetur adipiscing elit.'</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>The following will be the rendered output,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#268BD2;">Lorem</span><span style="color:#839496;"> </span><span style="color:#268BD2;">ipsum</span><span style="color:#839496;"> </span><span style="color:#268BD2;">dolor</span><span style="color:#839496;"> </span><span style="color:#268BD2;">sit</span><span style="color:#839496;"> </span><span style="color:#268BD2;">amet</span><span style="color:#839496;">,</span></span>
|
||
<span class="line"><span style="color:#268BD2;">consectetur</span><span style="color:#839496;"> </span><span style="color:#268BD2;">adipiscing</span><span style="color:#839496;"> </span><span style="color:#268BD2;">elit</span><span style="color:#839496;">.</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#268BD2;">Lorem</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">ipsum</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">dolor</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">sit</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">amet</span><span style="color:#657B83;">,</span></span>
|
||
<span class="line"><span style="color:#268BD2;">consectetur</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">adipiscing</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">elit</span><span style="color:#657B83;">.</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br><span class="line-number">2</span><br></div></div><div class="warning custom-block"><p class="custom-block-title">WARNING</p><p>But the situations where we want a backslash in a string to just be a backslash instead of a special code. By using <code>\\</code> would render the "just slash" to <code>\</code> on output, instead of a special character, as follows,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#2AA198;">"A newline character is written like </span><span style="color:#CB4B16;">\"\\</span><span style="color:#2AA198;">n</span><span style="color:#CB4B16;">\"</span><span style="color:#2AA198;">."</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#2AA198;">"A newline character is written like </span><span style="color:#CB4B16;">\"\\</span><span style="color:#2AA198;">n</span><span style="color:#CB4B16;">\"</span><span style="color:#2AA198;">."</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div></div><p>Strings cannot be divided, multiplied, or subtracted, unlike integers. But the <code>+</code> operator can be used on the. It concatenates (glues) the two strings together, the following example will produce the string "<code>concatenate</code>".</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#2AA198;">'con'</span><span style="color:#839496;"> </span><span style="color:#859900;">+</span><span style="color:#839496;"> </span><span style="color:#2AA198;">'cat'</span><span style="color:#839496;"> </span><span style="color:#859900;">+</span><span style="color:#839496;"> </span><span style="color:#2AA198;">'e'</span><span style="color:#839496;"> </span><span style="color:#859900;">+</span><span style="color:#839496;"> </span><span style="color:#2AA198;">'nate'</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#2AA198;">'con'</span><span style="color:#657B83;"> </span><span style="color:#859900;">+</span><span style="color:#657B83;"> </span><span style="color:#2AA198;">'cat'</span><span style="color:#657B83;"> </span><span style="color:#859900;">+</span><span style="color:#657B83;"> </span><span style="color:#2AA198;">'e'</span><span style="color:#657B83;"> </span><span style="color:#859900;">+</span><span style="color:#657B83;"> </span><span style="color:#2AA198;">'nate'</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><details class="details custom-block"><summary>1-1-3: Strings review</summary><ul><li>Nearly everything could be put into strings in JavaScript</li><li>String could be wrapped with <code>""</code> double quotation marks or <code>''</code> single quotation marks.</li><li>There is a tricky situation in JavaScript's string, where <code>\</code> backslash followed with a character are being introduced specially by the interpreter, such as <code>\n</code> referred as newline, <code>\t</code> referred as new tab. <ul><li><code>\\</code> double backslash will be rendered as a single <code>\</code>.</li><li><code>\&</code> symbols followed after slash will not contain its original function such as connecting, but will be rendered as <code>&</code> on output.</li></ul></li></ul></details><h3 id="_1-1-3-fr-further-reading" tabindex="-1">1-1-3-FR: Further Reading <a class="header-anchor" href="#_1-1-3-fr-further-reading" aria-label="Permalink to "1-1-3-FR: Further Reading""></a></h3><p>From the example given in the prior section with a lot of backslashes, it might be hard to understand the concept on at what time the slash will be rendered and when it will be considered as a special character starter.</p><p>The example is given as,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#2AA198;">"A newline character is written like </span><span style="color:#CB4B16;">\"\\</span><span style="color:#2AA198;">n</span><span style="color:#CB4B16;">\"</span><span style="color:#2AA198;">."</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#2AA198;">"A newline character is written like </span><span style="color:#CB4B16;">\"\\</span><span style="color:#2AA198;">n</span><span style="color:#CB4B16;">\"</span><span style="color:#2AA198;">."</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>The rendered output will be on print,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#268BD2;">A</span><span style="color:#839496;"> </span><span style="color:#268BD2;">newline</span><span style="color:#839496;"> </span><span style="color:#268BD2;">character</span><span style="color:#839496;"> </span><span style="color:#268BD2;">is</span><span style="color:#839496;"> </span><span style="color:#268BD2;">written</span><span style="color:#839496;"> </span><span style="color:#268BD2;">like</span><span style="color:#839496;"> </span><span style="color:#2AA198;">"</span><span style="color:#CB4B16;">\n</span><span style="color:#2AA198;">"</span><span style="color:#839496;">.</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#268BD2;">A</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">newline</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">character</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">is</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">written</span><span style="color:#657B83;"> </span><span style="color:#268BD2;">like</span><span style="color:#657B83;"> </span><span style="color:#2AA198;">"</span><span style="color:#CB4B16;">\n</span><span style="color:#2AA198;">"</span><span style="color:#657B83;">.</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>the backslash character (<code>\</code>) is used as an escape character to indicate that the following character(s) should be treated specially. In this case, the <code>"\n"</code> sequence is an escape sequence that represents a newline character. The backslash before the <code>n</code> character tells the JavaScript interpreter that it should treat the <code>n</code> as a special character and not just as the letter "n".</p><p>However, if we want to include an <strong>actual backslash character</strong> (<code>\</code>), we will have to <strong>escape it</strong> by using to two backslashes <code>\\</code>, or else with one single slash the JavaScript interpreter will still determines it as an special operator, Thus <code>\\</code> will print <code>\</code> on output.</p><ul><li><p><strong>But what about the quotation marks used within the quotation marks that wraps the string? Wouldn't JavaScript interpreter throw error?</strong></p><ul><li><p>In the given JavaScript string, the inner set of double quotation marks (<code>"\\n"</code>) is escaped using a backslash (<code>\</code>) character. This tells the JavaScript interpreter to treat the inner double quotation marks as a regular character instead of a string delimiter.</p><p>So when the string is rendered on output, the backslash character will be removed and the inner set of quotation marks will be displayed as a regular character. The rendered string will look like this,</p><div class="language-js vp-adaptive-theme line-numbers-mode"><button title="Copy Code" class="copy"></button><span class="lang">js</span><pre class="shiki solarized-dark vp-code-dark"><code><span class="line"><span style="color:#2AA198;">'</span><span style="color:#CB4B16;">\n</span><span style="color:#2AA198;">'</span></span></code></pre><pre class="shiki solarized-light vp-code-light"><code><span class="line"><span style="color:#2AA198;">'</span><span style="color:#CB4B16;">\n</span><span style="color:#2AA198;">'</span></span></code></pre><div class="line-numbers-wrapper" aria-hidden="true"><span class="line-number">1</span><br></div></div><p>The outer set of double quotation marks in the original string delimit the entire string and will be displayed as regular quotation marks.</p></li></ul></li></ul><blockquote><p><strong>Source</strong>: ChatGPT CA (Code Analysis)</p></blockquote></div></div></main><footer class="VPDocFooter" data-v-eb54b406 data-v-d801cd4d><!--[--><!--[--><!--[--><!--[--><!----><!--]--><!--]--><!--]--><!--]--><div class="edit-info" data-v-d801cd4d><div class="edit-link" data-v-d801cd4d><a class="VPLink link vp-external-link-icon no-icon edit-link-button" href="https://github.com/andatoshiki/toshiki-notebook/edit/master/docs/javascript/notes/1/1-1.md" target="_blank" rel="noreferrer" data-v-d801cd4d><!--[--><svg xmlns="http://www.w3.org/2000/svg" viewbox="0 0 24 24" class="edit-link-icon" aria-label="edit icon" data-v-d801cd4d><path d="M18,23H4c-1.7,0-3-1.3-3-3V6c0-1.7,1.3-3,3-3h7c0.6,0,1,0.4,1,1s-0.4,1-1,1H4C3.4,5,3,5.4,3,6v14c0,0.6,0.4,1,1,1h14c0.6,0,1-0.4,1-1v-7c0-0.6,0.4-1,1-1s1,0.4,1,1v7C21,21.7,19.7,23,18,23z"></path><path d="M8,17c-0.3,0-0.5-0.1-0.7-0.3C7,16.5,6.9,16.1,7,15.8l1-4c0-0.2,0.1-0.3,0.3-0.5l9.5-9.5c1.2-1.2,3.2-1.2,4.4,0c1.2,1.2,1.2,3.2,0,4.4l-9.5,9.5c-0.1,0.1-0.3,0.2-0.5,0.3l-4,1C8.2,17,8.1,17,8,17zM9.9,12.5l-0.5,2.1l2.1-0.5l9.3-9.3c0.4-0.4,0.4-1.1,0-1.6c-0.4-0.4-1.2-0.4-1.6,0l0,0L9.9,12.5z M18.5,2.5L18.5,2.5L18.5,2.5z"></path></svg> Edit this page on GitHub<!--]--></a></div><div class="last-updated" data-v-d801cd4d><p class="VPLastUpdated" data-v-d801cd4d data-v-43ed3de5>Last updated: <time datetime="2023-09-22T10:12:25.000Z" data-v-43ed3de5></time></p></div></div><!----></footer><!--[--><!--[--><!--[--><div id="comment-container"></div><!--]--><!--]--><!--]--></div></div></div><!--[--><!--]--></div></div><footer class="VPFooter has-sidebar" data-v-bb676018 data-v-855b7db4><div class="container" data-v-855b7db4><p class="message" data-v-855b7db4>Wrote with <i class="heart fa fa-heart fa-xs fa-beat"></i> and <i class="coffee fa fa-coffee fa-xs" aria-hidden="true"></i> by <a href="https://toshiki.dev">Anda Toshiki</a> at <code>root@andatoshiki:/~</code></p><p class="copyright" data-v-855b7db4>Copyright © 2023-2023 <a href="https://github.com/andatoshiki">Anda Toshiki</a>, <a href="https://github.com/lolilab">LoliLab</a> and <a href="https://github.com/toshikidev">Toshiki Dev</a> present <br /><span id="siteruntime_span"></span></p></div></footer><!--[--><!--]--></div></div>
|
||
<script>window.__VP_HASH_MAP__=JSON.parse("{\"academic_chemistry_index.md\":\"4ce8123c\",\"academic_chemistry_notes_12-5.md\":\"b2ba8c2f\",\"academic_chemistry_problems_02-20.md\":\"8cb29599\",\"academic_physics_index.md\":\"d25757f4\",\"academic_chemistry_problems_03-02-2.md\":\"cddc478e\",\"academic_chemistry_problems_03-02-3.md\":\"0a24d410\",\"academic_literature_index.md\":\"ac4649ac\",\"academic_literature_writing_methods-of-development.md\":\"0f74df81\",\"development_aws_license.md\":\"29dcd536\",\"application_vitepress-plugin-shiki-twoslash_config_reference.md\":\"60eb9204\",\"application_vitepress-plugin-shiki-twoslash_guide_markdown-extensions.md\":\"02daad05\",\"application_vitepress-plugin-shiki-twoslash_index.md\":\"668032c6\",\"development_aws_acknowledgement.md\":\"0f1b2e80\",\"development_aws_appendix.md\":\"4db0fe7b\",\"academic_chemistry_problems_03-02-1.md\":\"0b7bef7d\",\"development_aws_assignments.md\":\"bf3507ab\",\"development_aws_author.md\":\"0b99b863\",\"development_aws_aws-batch.md\":\"cc0e476b\",\"development_aws_aws-get-started.md\":\"ac41a9ec\",\"development_aws_closing.md\":\"e9b29136\",\"development_aws_cloud.md\":\"e0a3351b\",\"development_aws_docker-system.md\":\"199ab664\",\"development_aws_handson-bashoutter.md\":\"02a97c87\",\"development_aws_index.md\":\"16c9957a\",\"application_vitepress-plugin-shiki-twoslash_guide_custom-theme.md\":\"b8abe751\",\"academic_physics_ipho-formulas-jpn_10.md\":\"ef896d30\",\"development_aws_handson-jupyter.md\":\"921139c0\",\"academic_physics_ipho-formulas-jpn_12.md\":\"668f0a14\",\"application_vitepress-plugin-shiki-twoslash_config_flags.md\":\"239f91e1\",\"academic_physics_ipho-formulas-jpn_9.md\":\"8567a474\",\"academic_physics_ipho-formulas-jpn_11.md\":\"34b3c009\",\"development_aws_handson-ec2.md\":\"3b193c9d\",\"application_markdown-it-katex_tips.md\":\"2f5a6fac\",\"development_aws_handson-serverless.md\":\"47096940\",\"academic_physics_ipho-formulas-jpn_1.md\":\"6b8a8538\",\"academic_physics_ipho-formulas-jpn_8.md\":\"62b69d92\",\"development_aws_handson-qabot.md\":\"e83676c0\",\"academic_physics_ipho-formulas-jpn_4.md\":\"134bc32b\",\"academic_physics_ipho-formulas-jpn_3.md\":\"df1aa8c8\",\"academic_physics_ipho-formulas-jpn_7.md\":\"522557a7\",\"academic_physics_ipho-formulas-jpn_6.md\":\"d3c1c248\",\"application_vitepress-plugin-shiki-twoslash_api_types.md\":\"88dff72d\",\"academic_physics_ipho-formulas-jpn_2.md\":\"8a5fc800\",\"academic_physics_ipho-formulas-jpn_5.md\":\"173a5224\",\"academic_vocabulary_index.md\":\"65e0ee75\",\"academic_vocabulary_2023_02_2023-02-27.md\":\"1611efa2\",\"application_markdown-it-katex_how-to-use.md\":\"82f0decf\",\"application_vitepress-plugin-shiki-twoslash_api_annotations.md\":\"62a4e151\",\"academic_physics_ipho-formulas-jpn_13.md\":\"ccc7f6f2\",\"application_vitepress-plugin-shiki-twoslash_api_logging.md\":\"d4d49edd\",\"application_vitepress-plugin-shiki-twoslash_api_multi-file.md\":\"7587d3a3\",\"application_vitepress-plugin-shiki-twoslash_api_includes.md\":\"ba321a0c\",\"application_vitepress-plugin-shiki-twoslash_api_queries.md\":\"90e6bc0c\",\"javascript_notes_1_1-2.md\":\"5f631c7d\",\"development_aws_scientific-computing.md\":\"9c20f9c7\",\"development_aws_serverless.md\":\"65c8f921\",\"development_aws_webserver.md\":\"40751c5b\",\"application_vitepress-plugin-shiki-twoslash_api_cutting.md\":\"bb3b57bd\",\"development_file-naming-convention.md\":\"c3012daf\",\"development_rclone-for-r2.md\":\"a5dbabb7\",\"getting-started.md\":\"814d62c3\",\"index.md\":\"daf1f48b\",\"javascript_notes_1_1-1.md\":\"37d06ab5\",\"save_reading_outliers_4.md\":\"4689d90c\",\"jp_index.md\":\"951bc2be\",\"application_markdown-it-katex_support-table.md\":\"4112f817\",\"roadmap.md\":\"3b4a111e\",\"save_reading_index.md\":\"75362a1c\",\"development_aws_main.md\":\"d42ddf84\",\"save_reading_outliers_1.md\":\"e44fa446\",\"save_reading_outliers_2.md\":\"c0d565cf\",\"save_reading_outliers_3.md\":\"7cdc7083\",\"application_vitepress-plugin-shiki-twoslash_api_emit.md\":\"52af75b3\",\"application_vitepress-plugin-shiki-twoslash_api_errors.md\":\"2d34f79f\",\"application_markdown-it-katex_support-function.md\":\"cad3972a\"}");window.__VP_SITE_DATA__=JSON.parse("{\"lang\":\"en-US\",\"dir\":\"ltr\",\"title\":\"Toshiki's Note\",\"description\":\"Toshiki's web notebook served via Vitepress!\",\"base\":\"/\",\"head\":[],\"appearance\":true,\"themeConfig\":{\"nav\":[{\"text\":\"Development\",\"link\":\"/development/\"},{\"text\":\"Academic\",\"items\":[{\"text\":\"K-12\",\"items\":[{\"text\":\"Chemistry\",\"link\":\"/academic/chemistry/index\",\"activeMatch\":\"/academic/chemistry/\"},{\"text\":\"Discrete Math.\",\"link\":\"/discrete-math/index\",\"activeMatch\":\"/categories/fragments/\"},{\"text\":\"Literature\",\"link\":\"/academic/literature/index\",\"activeMatch\":\"/academic/literature/\"}]},{\"text\":\"Tools\",\"items\":[{\"text\":\"Formulas for IPhO JPN.\",\"link\":\"/academic/physics/ipho-formulas-jpn/1\",\"activeMatch\":\"/academic/physics/ipho-formulas-jpn/\"}]},{\"text\":\"\",\"link\":\"\",\"activeMatch\":\"\"},{\"text\":\"\",\"link\":\"\",\"activeMatch\":\"\"},{\"text\":\"\",\"link\":\"\",\"activeMatch\":\"\"},{\"text\":\"\",\"link\":\"\",\"activeMatch\":\"\"},{\"text\":\"\",\"link\":\"\",\"activeMatch\":\"\"},{\"text\":\"\",\"link\":\"\",\"activeMatch\":\"\"},{\"text\":\"\",\"link\":\"\",\"activeMatch\":\"\"}],\"activeMatch\":\"/academic/\"},{\"text\":\"Application\",\"items\":[{\"text\":\"Personal projects\",\"items\":[{\"text\":\"markdown-it-katex\",\"link\":\"/application/markdown-it-katex/how-to-use\",\"activeMatch\":\"/application/markdown-it-katex/\"},{\"text\":\"vitepress-plugin-shiki-twoslash\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/index\",\"activeMatch\":\"/application/vitepress-plugin-shiki-twoslash/index\"}]}],\"activeMatch\":\"/save/\"},{\"text\":\"Save\",\"items\":[{\"text\":\"Reading\",\"link\":\"/save/reading/index\",\"activeMatch\":\"/save/reading/\"},{\"text\":\"Vocabulary\",\"link\":\"/academic/vocabulary/index\",\"activeMatch\":\"/academic/vocabulary/\"}],\"activeMatch\":\"/save/\"}],\"sidebar\":{\"/development/\":[{\"text\":\"Notes & Issues\",\"collapsed\":false,\"items\":[{\"text\":\"File Naming Convention\",\"link\":\"/development/file-naming-convention\"},{\"text\":\"RClone for R2\",\"link\":\"/development/rclone-for-r2\"}]},{\"text\":\"コードで学ぶAWS入門\",\"collapsed\":false,\"items\":[{\"text\":\"背景\",\"link\":\"/development/aws/index\"},{\"text\":\"はじめに!\",\"link\":\"/development/aws/main\"},{\"text\":\"クラウド概論\",\"link\":\"/development/aws/cloud.md\"},{\"text\":\"AWS 入門\",\"link\":\"/development/aws/aws-get-started\"},{\"text\":\"Hands-on 1: 初めての EC2 インスタンスを起動する\",\"link\":\"/development/aws/handson-ec2.md\"},{\"text\":\"クラウドで行う科学計算・機械学習\",\"link\":\"/development/aws/scientific-computing.md\"},{\"text\":\"Hands-on 2: AWS でディープラーニングを実践\",\"link\":\"/development/aws/handson-ec2.md\"},{\"text\":\"Docker 入門\",\"link\":\"/development/aws/docker-system\"},{\"text\":\"Hands-on 3: AWS で自動質問回答ボットを走らせる\",\"link\":\"/development/aws/handson-qabot\"},{\"text\":\"Hands-on 4: AWS Batch を使って機械学習のハイパーパラメータサーチを並列化する\",\"link\":\"/development/aws/aws-batch\"},{\"text\":\"Web サービスの作り方\",\"link\":\"/development/aws/webserver\"},{\"text\":\"Serverless architecture\",\"link\":\"/development/aws/serverless\"},{\"text\":\"Hands-on 5: サーバーレス入門\",\"link\":\"/development/aws/handson-serverless\"},{\"text\":\"Hands-on 6: Bashoutter\",\"link\":\"/development/aws/handson-bashoutter\"},{\"text\":\"まとめ\",\"link\":\"/development/aws/closing\"},{\"text\":\"ppendix: 環境構築\",\"link\":\"/development/aws/appendix\"},{\"text\":\"謝辞\",\"link\":\"/development/aws/acknowledgement\"}]}],\"/academic/chemistry/\":[{\"text\":\"Textbook\",\"collapsed\":true,\"items\":[{\"text\":\"12-5: Reaction Mechanism\",\"link\":\"/academic/chemistry/notes/12-5\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"}]},{\"text\":\"Kinetics\",\"collapsed\":false,\"items\":[{\"text\":\"Rate determining steps\",\"link\":\"/academic/chemistry/notes/kinetics/rate-determining-step\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"}]},{\"text\":\"Problems & Solutions\",\"collapsed\":true,\"items\":[{\"text\":\"Problem: 02-20\",\"link\":\"/academic/chemistry/problems/02-20\"},{\"text\":\"Problem: 03-02-1\",\"link\":\"/academic/chemistry/problems/03-02-1\"},{\"text\":\"Problem: 03-02-2\",\"link\":\"/academic/chemistry/problems/03-02-2\"},{\"text\":\"Problem: 03-02-3\",\"link\":\"/academic/chemistry/problems/03-02-3\"}]}],\"/academic/physics\":[{\"text\":\"IPhO Formulas: JP Ver.\",\"collapsed\":false,\"items\":[{\"text\":\"1: 数学\",\"link\":\"/academic/physics/ipho-formulas-jpn/1\"},{\"text\":\"2: 一般的な推奨事\",\"link\":\"/academic/physics/ipho-formulas-jpn/2\"},{\"text\":\"3: 運動学\",\"link\":\"/academic/physics/ipho-formulas-jpn/3\"},{\"text\":\"4: 力学\",\"link\":\"/academic/physics/ipho-formulas-jpn/4\"},{\"text\":\"5: 振動と波\",\"link\":\"/academic/physics/ipho-formulas-jpn/5\"},{\"text\":\"6: 幾何光学,測光\",\"link\":\"/academic/physics/ipho-formulas-jpn/6\"},{\"text\":\"7: 波動光学\",\"link\":\"/academic/physics/ipho-formulas-jpn/7\"},{\"text\":\"8: 電気回路\",\"link\":\"/academic/physics/ipho-formulas-jpn/8\"},{\"text\":\"9: 電磁気学\",\"link\":\"/academic/physics/ipho-formulas-jpn/9\"},{\"text\":\"10: 熱力\",\"link\":\"/academic/physics/ipho-formulas-jpn/10\"},{\"text\":\"11: 量子力学\",\"link\":\"/academic/physics/ipho-formulas-jpn/11\"},{\"text\":\"12: Keplerの法則\",\"link\":\"/academic/physics/ipho-formulas-jpn/12\"},{\"text\":\"13: 相対性理論\",\"link\":\"/academic/physics/ipho-formulas-jpn/13\"}]}],\"/academic/vocabulary/\":[{\"text\":\"Vocabulary\",\"collapsed\":true,\"items\":[{\"text\":\"2023-02-27\",\"link\":\"/academic/vocabulary/2023/02/2023-02-27\"}]}],\"/academic/literature/\":[{\"text\":\"Writing Resources\",\"collapsed\":true,\"items\":[{\"text\":\"Patterns of Organization and Methods of Development\",\"link\":\"/academic/literature/writing/methods-of-development\"}]}],\"/javascript/\":[{\"text\":\"1: Basic JavaScript-Value, Variables, and Control Flow\",\"collapsed\":true,\"items\":[{\"text\":\"1-1: Numbers\",\"link\":\"/javascript/notes/1/1-1\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"},{\"text\":\"\",\"link\":\"\"}]}],\"/save/reading/\":[{\"text\":\"Outliers\",\"collapsed\":true,\"items\":[{\"text\":\"Introduction & Chapter 1: The Roseto Mystery\",\"link\":\"/save/reading/outliers/1\"},{\"text\":\"Chapter 2: The 10,000-Hour Rule\",\"link\":\"/save/reading/outliers/2\"},{\"text\":\"Chapter 3: The Trouble with Geniuses, Part 1\",\"link\":\"/save/reading/outliers/3\"},{\"text\":\"Chapter 4: The Trouble with Geniuses, Part 2\",\"link\":\"/save/reading/outliers/4\"}]}],\"/application/markdown-it-katex/\":[{\"text\":\"markdown-it-katex\",\"collapsed\":false,\"items\":[{\"text\":\"1: How to use?\",\"link\":\"/application/markdown-it-katex/how-to-use\"},{\"text\":\"2: KaTeX supported functions\",\"link\":\"/application/markdown-it-katex/support-function\"},{\"text\":\"3: KaTeX support tables\",\"link\":\"/application/markdown-it-katex/support-table\"},{\"text\":\"4: Tips\",\"link\":\"/application/markdown-it-katex/tips\"}]}],\"/application/vitepress-plugin-shiki-twoslash/\":[{\"text\":\"Guide\",\"collapsed\":false,\"items\":[{\"text\":\"Getting Started\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/\"},{\"text\":\"Markdown Extensions\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/guide/markdown-extensions\"},{\"text\":\"Using a Custom Theme\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/guide/custom-theme\"}]},{\"text\":\"Features\",\"collapsed\":false,\"items\":[{\"text\":\"Queries\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/queries\"},{\"text\":\"Errors\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/errors\"},{\"text\":\"Emit\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/emit\"},{\"text\":\"Cutting\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/cutting\"},{\"text\":\"Multi-file\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/multi-file\"},{\"text\":\"@types\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/types\"},{\"text\":\"Meta Annotations\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/annotations\"},{\"text\":\"Logging\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/logging\"},{\"text\":\"Includes\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/api/includes\"}]},{\"text\":\"Config\",\"collapsed\":false,\"items\":[{\"text\":\"Reference\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/config/reference\"},{\"text\":\"Compiler Flags\",\"link\":\"/application/vitepress-plugin-shiki-twoslash/config/flags\"}]}]},\"footer\":{\"copyright\":\"Copyright © 2023-2023 <a href=\\\"https://github.com/andatoshiki\\\">Anda Toshiki</a>, <a href=\\\"https://github.com/lolilab\\\">LoliLab</a> and <a href=\\\"https://github.com/toshikidev\\\">Toshiki Dev</a> present <br /><span id=\\\"siteruntime_span\\\"></span>\",\"message\":\"Wrote with <i class=\\\"heart fa fa-heart fa-xs fa-beat\\\"></i> and <i class=\\\"coffee fa fa-coffee fa-xs\\\" aria-hidden=\\\"true\\\"></i> by <a href=\\\"https://toshiki.dev\\\">Anda Toshiki</a> at <code>root@andatoshiki:/~</code>\"},\"logo\":\"/logos/logo.png\",\"outline\":\"deep\",\"outlineTitle\":\"TOC\",\"outlineBadges\":false,\"lastUpdatedText\":\"Last updated\",\"algolia\":{\"appId\":\"G9IUR45K98\",\"apiKey\":\"8528cc91281d8112b28f508317a96dd3\",\"indexName\":\"toshiki-notebook\"},\"editLink\":{\"pattern\":\"https://github.com/andatoshiki/toshiki-notebook/edit/master/docs/:path\",\"text\":\"Edit this page on GitHub\"},\"socialLinks\":[{\"icon\":\"github\",\"link\":\"https://github.com/andatoshiki\"},{\"icon\":\"twitter\",\"link\":\"https://twitter.com/andatoshiki\"}]},\"locales\":{\"/\":{\"label\":\"English\",\"lang\":\"en-US\"},\"/jp/\":{\"label\":\"Japanese\",\"title\":\"Vue Test Utils\",\"lang\":\"jp-JP\",\"description\":\"La documentation officielle de Vue Test Utils\"}},\"scrollOffset\":90,\"cleanUrls\":true}");</script>
|
||
|
||
</body>
|
||
</html> |