Skip to content

Commit 6945396

Browse files
Improved accuracy of Description for convert-string-to-ascii for better functional representation
Renamed `convert-string-to-ascii.md` to `convert-string-to-unicode.md` Replaced ASCII with Unicode Kept `ascii` tag as it is a subset of unicode and to minimize search errors Fixed issue #192
1 parent c3f21fb commit 6945396

File tree

2 files changed

+14
-14
lines changed

2 files changed

+14
-14
lines changed

snippets/python/string-manipulation/convert-string-to-ascii.md

Lines changed: 0 additions & 14 deletions
This file was deleted.
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
---
2+
title: Convert String to Unicode
3+
description: Converts a string into its Unicode representation.
4+
author: axorax
5+
tags: string,ascii,unicode,convert
6+
---
7+
8+
```py
9+
def string_to_unicode(s):
10+
return [ord(char) for char in s]
11+
12+
# Usage:
13+
string_to_unicode('hello') # Returns: [104, 101, 108, 108, 111]
14+
```

0 commit comments

Comments
 (0)