index.html 3.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104
  1. <!doctype html>
  2. <html>
  3. <head>
  4. <meta charset="utf-8">
  5. <meta name="viewport" content="width=device-width, initial-scale=1" />
  6. <link rel="canonical" href="https://jamesfengcao.gitlab.io/uweb/zh/bc/" />
  7. <link rel="stylesheet" href="../style.css#" type="text/css" />
  8. <title>超级计算器(bc)</title>
  9. <script>
  10. function findLang(){
  11. let href = location.href;
  12. for(let i=href.length-1;i>0;i--){
  13. if('/'==href.charAt(i) && '/'==href.charAt(i-3))
  14. return i;
  15. }
  16. return 0;
  17. }
  18. function nav2(page){
  19. let i = findLang();
  20. location.href = location.href.substring(0,i+1)+page;
  21. }
  22. function nav2Lang(lang){
  23. let i = findLang();
  24. let href = location.href;
  25. location.href = location.href.substring(0,i-2)+lang+location.href.substring(i);
  26. }
  27. </script>
  28. </head>
  29. <body>
  30. <header class='header'>
  31. <a class="logo" href="javascript:void(0)" onclick="return nav2('index.html#')">首页</a> <a class="logo" href="javascript:void(0)" onclick="return nav2('tags/index.html#')">标签</a>
  32. <nav>
  33. </nav>
  34. </header>
  35. <br />
  36. <div class="container">
  37. <h1 class="title">超级计算器(bc)
  38. <br>
  39. <span class="subtitle"></span>
  40. </h1>
  41. <ul class="tags">
  42. </ul>
  43. <p>Gnu bc计算器支持无限精度,可扩展函数库、常数库。</p>
  44. <h3 id="安装bc-android11无需安装">安装bc (Android11+无需安装)</h3>
  45. <ul>
  46. <li>安装<a href="../searchurl/plugins.html">uweb定制Termux应用</a></li>
  47. <li>Termux下运行以下命令:<br>
  48. apt update<br>
  49. apt upgrade<br>
  50. apt install bc</li>
  51. </ul>
  52. <h3 id="使用书签调用计算器">使用书签调用计算器</h3>
  53. <p>&quot;长按以下链接-&gt;命令-&gt;书签&quot;可保存链接为书签。书签菜单可至<a href="../urls/index.html#">特色服务网页</a>安装。<br>
  54. <a href="c:bc -l">bc</a><br>
  55. <a href="c:bc -l *.bc">全能bc</a></p>
  56. <h3 id="浏览器地址栏作为超级计算器">浏览器地址栏作为超级计算器</h3>
  57. <p>配置文件default.acmd如下:<br>
  58. 计算器:text/html:echo &quot;%s&quot;|bc -l -q</p>
  59. <h3 id="更多bc扩展库">更多bc扩展库:</h3>
  60. <p>https://github.com/susca/bc-extensions<br>
  61. http://phodd.net/gnu-bc<br>
  62. http://www.numbertheory.org/gnubc/gnubc.html</p>
  63. <h3 id="使用扩展库以后defaultacmd配置如下">使用扩展库以后default.acmd配置如下:</h3>
  64. <p>计算器:text/html:echo &quot;%s&quot;|bc -l -q extensions.bc scientific_constants.bc<br>
  65. 全能计算器:text/html:echo &quot;%s&quot;|bc -l -q *.bc</p>
  66. </div>
  67. <p>Last Modified: 2 April 2024<br>
  68. add js function in README<br>
  69. <pre></pre>
  70. </p>
  71. <script id='jsgiscus'
  72. src='https://giscus.app/client.js'
  73. data-repo="torappinfo/uweb"
  74. data-repo-id="MDEwOlJlcG9zaXRvcnkzMDIyMDU3MjE="
  75. data-category="Announcements"
  76. data-category-id="DIC_kwDOEgNLGc4CQjsh"
  77. data-mapping="title"
  78. data-strict="0"
  79. data-reactions-enabled="1"
  80. data-emit-metadata="0"
  81. data-input-position="top"
  82. data-theme="light"
  83. data-lang="en"
  84. data-loading="lazy"
  85. crossorigin="anonymous" async>
  86. </script>
  87. <footer class="site-footer">
  88. <div class="container">
  89. &copy; 2018-2024 Richard H. Cao
  90. </div>
  91. </footer>
  92. <!-- This document is licensed under the GNU Free Documentation License, Version 1.3 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts, and no Back-Cover Texts. A copy of the license is available at <https://www.gnu.org/licenses/>. -->
  93. </body>
  94. </html>