--- warning: This file is auto generated by `yarn web:inject`, do not edit by hand examples: - digits() returns: - '''0123456789''' dependencies: [] authors: original by: - Kevin van Zonneveld (https://kvz.io) notes: - Returns the string '0123456789' parityVerified: - Python 3.12 isTypescript: true type: function layout: function title: Python's string.digits in TypeScript description: >- Here's what our current TypeScript equivalent to Python's string.digits looks like. function: digits category: string language: python permalink: python/string/digits/ alias: - /functions/python/digits/ - /functions/string/digits/ - /python/digits/ ---
{% codeblock lang:typescript %}export function digits(): '0123456789' { // discuss at: https://locutus.io/python/digits/ // parity verified: Python 3.12 // original by: Kevin van Zonneveld (https://kvz.io) // note 1: Returns the string '0123456789' // example 1: digits() // returns 1: '0123456789' return '0123456789' } {% endcodeblock %}