Catalog npm
Back to packageRELEASE DETAILS

1.0.1

npm

10print

Nodejs implementation of the famous one-line Commodore 64 BASIC program

10printcommodorejavascriptcommodore64pattern
Published22 Oct 2018
Direct dependencies0
Transitive dependenciesNot calculated

README

Current package documentation

10print

Nodejs implementation of the famous one-line Commodore 64 BASIC program:

10 PRINT CHR$(205.5+RND(1)); : GOTO 10. 

This project was inspired by 10 PRINT book (http://10print.org/) where you can find all the information about the original program. This script will print on the console an infinite random sequence composed only by chars / and \ in a fancy pattern.

Getting Started

To run this script you only need to install and import the npm package, then running the goto10 function. Of course don't forget to kill the process to interrupt the infinite loop :)

Installing

npm install 10print

Usage

For a basic usage run goto10() to print the standard pattern:

let p = require("10print");
p.goto10();

If you want to create your own custom pattern it's possible to call printPattern(config) in this way:

p.printPattern({
    symbol1: "/", // The first symbol of your pattern
    symbol2: "\\", // The second symbol of your pattern
    weight: 0.5 // Value between 0 and 1 that tunes the probability of each symbol to be displayed
})

This is the configuration of the standard pattern. Changing weight value would create a new one with different symbol frequency: setting 0 means to have 100% chance to get first symbol, 1 means 100% chance to get second. With 0.5 there is 50% chance for each symbol. You can change this value and the symbols as well to create your custom pattern.

Developing

Install all the dependencies:

npm install

No build is needed. To run the tests:

npm test

License

This project is licensed under the MIT License - see the LICENSE.md file for details

Acknowledgments

Downloads & popularity

Awaiting observations

No metric observations yet

Download counts and popularity will appear here as the collector receives them.

Declared dependencies 0

Native requirements
0 direct targetsNot calculated transitive count
No declared dependencies in this collected response

Declarations describe requirements; they are not a resolved dependency graph.

Distribution files

1 collected
Distribution 1

Source distribution

Source file
Checksums from source
{
  "integrity": "sha512-R/9oR02yydpr7dtzOL+ZNLDRXZFfdduEhi8zBEqTolRalISZFXSmVxFzizaAwrw2qqw50IEnHCi2MSLheN8INw==",
  "shasum": "76ac4725a1b39ccb66afe582eda1423a282af1ec",
  "tarball": "https://registry.npmjs.org/10print/-/10print-1.0.1.tgz",
  "fileCount": 3,
  "unpackedSize": 1559,
  "npm-signature": "-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbzRbVCRA9TVsSAnZWagAA8mUQAIBKkR6PmYJoGwOxETDH\nkqeP1tp7Wv3wS0pRIKzHNEaS1oeMuuvs+36thJX7R7M18dVsv3ojL6iH0obM\nbLfjumpFVwiEtmL2YZEM7Gsw6RDuJnOBHe4TARS9PIgxEE7L0m3Z+pB4RTzo\n8PAfMDCW5GvsLOJKwpIbmye9fZfKRukH+nVXlll4SPoE5dn+6jLz6eervcf4\nsuF26b7KPfcxVDBOav/s+9jEprkZk0+kMXadOa+82vCUE23qR9+CQkyuT+Kq\nJ2h+Lu25NSmZ4ZFquMdBnZXA0RvN55dv2B1XOVYS50chaMf46ADJ1qLg67v0\neVt7hiqvsrG7r8IFz+rNZLVS3ns4PZkE6hCirHZv9fBbkqecgTQ/6SlUqhoK\nSq4zJvsswvwndO7H/y8NyMjQoQypTzTKvva8uMNHed0qDlfoTLTK7ZrbZR3d\nVAqWaJ3A0FuABE02B8LOBkjvfm6UpWItU7J1pEUchLBqbIrbh+rPjy1hHxRe\nJdqG9ikhmW1cyZx9TICTS3MX/gqdfIjmIBI1CdzuLCOB8U7FswtrTIhZu659\nH5ATz+d1Txq62CqgeMOjlRIhhrJ/eVhG2n5jO2uzAZ8DWztSYBZTDSFy+VSX\nMHcWzzgKNbo2SX7UMTBrBt+xv5ZUfJrpaqBiOqHn7Hhc77I5j1nBmEZM9iXQ\nIOS5\r\n=LAYB\r\n-----END PGP SIGNATURE-----\r\n",
  "signatures": [
    {
      "keyid": "SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA",
      "sig": "MEUCIBlNIQWyKGATlkU9BM/MhaEhRaY3ltTLTPNFzPBwciNpAiEA2zRJ3wi9t8+HlvdNnEaWA5HsgNV9um9RyqHpx3JzMgk="
    }
  ]
}

Repository

PENDING
luca1388/10print

Shared repository data · GitHub

License detected in repository
Not collected

Metadata history

Meaningful changes
Current collected state Current

Observed since 20 Oct, 18:01 UTC

No superseded metadata states collected. Unchanged observations do not create new revisions.

Record identity

package_version:999af286721518666c050b31225b0495dd4c8bd2c9873fa5fbeff8e83ffa4cf7

Other collected versions

2.0.011 Mar1.2.211 Mar1.2.129 Oct1.2.029 Oct1.1.024 Oct1.0.021 OctView all collected versions →