---
title: "Discussion on \"1945. Sum of Digits of String After Convert\" | Hashnode"
description: "Discussion on \"1945. Sum of Digits of String After Convert\". class Solution:\n    def getLucky(self, s: str, k: int) -> int:\n        EXTRA = 96\n        letters = []\n\n        def convert(val):\n            nonlocal letters            \n            letters = []\n            strVal = str(val)\n            for c in str..."
url: "https://hashnode.com/posts/1945-sum-of-digits-of-string-after-convert/66d73d7ec90cd1edbcdef327"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [1945\. Sum of Digits of String After Convert](https://tapanrachchh.hashnode.dev/1945-sum-of-digits-of-string-after-convert?utm_source=hashnode&utm_medium=feed)

class Solution: def getLucky(self, s: str, k: int) -> int: EXTRA = 96 letters = \[\] def convert(val): nonlocal letters letters = \[\] strVal = str(val) for c in str...

Sep 3, 2024 · 1 min read · tapanrachchh.hashnode.dev  
Read the article

-   [#python](https://hashnode.com/tag/python)
-   [#leetcode](https://hashnode.com/tag/leetcode)
-   [#string](https://hashnode.com/tag/string)
-   [#simulation](https://hashnode.com/tag/simulation)

## Written by

[Tapan Rachchh](https://hashnode.com/@tapanrachchh)

@tapanrachchh

  
[View profile](https://hashnode.com/@tapanrachchh)

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
