Giter Site home page Giter Site logo

bd's Introduction

bd

字符串和进制编码解析工具

Installation

go install github.com/biningo/bd@latest

Features

  • 支持10进制、2进制、16进制互转
  • 支持解析UTF-8编码的字符串

Usage

bd "hello,世界" -t s
hello,世界
+------+----------------+------------------+
| CHAR |    UNICODE     |       UTF8       |
+------+----------------+------------------+
| h    | \u68 (104)     | [0x68]           |
| e    | \u65 (101)     | [0x65]           |
| l    | \u6c (108)     | [0x6c]           |
| l    | \u6c (108)     | [0x6c]           |
| o    | \u6f (111)     | [0x6f]           |
| ,    | \u2c (44)      | [0x2c]           |
| 世   | \u4e16 (19990) | [0xe4 0xb8 0x96] |
| 界   | \u754c (30028) | [0xe7 0x95 0x8c] |
+------+----------------+------------------+
bd 200
bd -t d 200
200
0xc8
11001000
+----------+
| 0xc8     |
| 11001000 |
+----------+
bd -t h 0xc8
200
0xc8
11001000
+----------+
| 0xc8     |
| 11001000 |
+----------+
bd -t b 11001000
200
0xc8
11001000
+----------+
| 0xc8     |
| 11001000 |
+----------+

bd's People

Contributors

biningo avatar

Stargazers

 avatar  avatar  avatar  avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.