Skip to content

Commit

Permalink
Created using Colab
Browse files Browse the repository at this point in the history
  • Loading branch information
sualeh committed May 7, 2024
1 parent a4907ba commit 7150874
Showing 1 changed file with 80 additions and 58 deletions.
138 changes: 80 additions & 58 deletions Notebooks/3_javascript_unicode_numbers.ipynb
Original file line number Diff line number Diff line change
@@ -1,60 +1,82 @@
{
"cells": [
{
"cell_type": "markdown",
"metadata": {},
"source": [
"# Parsing Numbers"
]
"cells": [
{
"cell_type": "markdown",
"metadata": {
"id": "view-in-github",
"colab_type": "text"
},
"source": [
"<a href=\"https://colab.research.google.com/github/sualeh/What-a-Character/blob/main/Notebooks/3_javascript_unicode_numbers.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "QSDytF77dSgu"
},
"source": [
"# Parsing Numbers"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "Gw8C8NhFdSgu"
},
"source": [
"## Handle Unicode Numbers"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {
"id": "BdKZMWKAdSgv"
},
"outputs": [],
"source": [
"%%script node\n",
"\n",
"hindiNumber = \"१२३४५६७८९०\";\n",
"number = parseInt(hindiNumber);\n",
"\n",
"console.log(`${hindiNumber} = ${number}`);"
]
},
{
"cell_type": "markdown",
"metadata": {
"id": "VD1YDMY-dSgv"
},
"source": [
"> **NOTE:** Parsing numeric values from other languages DOES NOT work."
]
}
],
"metadata": {
"kernelspec": {
"display_name": "base",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.5"
},
"colab": {
"provenance": [],
"include_colab_link": true
}
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"## Handle Unicode Numbers"
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": [
"%%script node\n",
"\n",
"hindiNumber = \"१२३४५६७८९०\";\n",
"number = parseInt(hindiNumber);\n",
"\n",
"console.log(`${hindiNumber} = ${number}`);"
]
},
{
"cell_type": "markdown",
"metadata": {},
"source": [
"> **NOTE:** Parsing numeric values from other languages DOES NOT work."
]
}
],
"metadata": {
"kernelspec": {
"display_name": "base",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.11.5"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
"nbformat": 4,
"nbformat_minor": 0
}

0 comments on commit 7150874

Please sign in to comment.