Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #85391

Re: Please help.

Path csiph.com!usenet.pasdenom.info!gegeweb.org!usenet-fr.net!nerim.net!novso.com!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail
Return-Path <d@davea.name>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.020
X-Spam-Evidence '*H*': 0.96; '*S*': 0.00; 'python,': 0.02; 'string.': 0.05; 'variables': 0.07; 'bash': 0.09; 'function,': 0.09; 'developers,': 0.11; 'python': 0.11; 'itself.': 0.14; 'language.': 0.14; 'attends': 0.16; 'bind': 0.16; 'exceptions,': 0.16; 'grep': 0.16; 'keyword,': 0.16; 'language:': 0.16; 'translated.': 0.16; 'words.': 0.16; 'language': 0.16; 'wrote:': 0.18; 'library': 0.18; 'trying': 0.19; 'translated': 0.19; 'command': 0.22; 'print': 0.22; 'header:User-Agent:1': 0.23; '2.x': 0.24; 'specify': 0.24; 'solutions.': 0.26; 'this:': 0.26; 'header:In-Reply-To:1': 0.27; 'function': 0.29; 'words': 0.29; '(like': 0.30; 'code': 0.31; '>>>>': 0.31; 'are.': 0.31; 'keywords,': 0.31; 'file': 0.32; 'linux': 0.33; 'url:python': 0.33; 'running': 0.33; 'monday,': 0.33; 'problem.': 0.35; 'but': 0.35; 'there': 0.35; 'really': 0.36; 'functions.': 0.36; "he's": 0.36; 'in.': 0.36; 'mentor': 0.36; "didn't": 0.36; 'url:org': 0.36; 'changing': 0.37; 'example,': 0.37; 'so,': 0.37; 'version,': 0.38; 'to:addr:python- list': 0.38; 'pm,': 0.38; 'to:addr:python.org': 0.39; 'either': 0.39; 'hope': 0.61; 'helps': 0.61; 'new': 0.61; 'john': 0.61; 'you.': 0.62; 'times': 0.62; 'email addr:gmail.com': 0.63; 'name': 0.63; 'real': 0.63; 'skip:n 10': 0.64; 'pick': 0.64; 'stand': 0.64; 'more': 0.64; 'charset:windows-1252': 0.65; 'line,': 0.68; 'received:74.208': 0.68; 'presented': 0.69; 'wish': 0.70; 'inline': 0.74; '2014,': 0.84; '2015': 0.84; 'learn.': 0.84
Date Mon, 09 Feb 2015 13:25:40 -0500
From Dave Angel <d@davea.name>
User-Agent Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.4.0
MIME-Version 1.0
To python-list@python.org
Subject Re: Please help.
References <mailman.18570.1423503843.18130.python-list@python.org> <ff0a15e0-8d30-4d56-b28a-7d92a99e7d6c@googlegroups.com>
In-Reply-To <ff0a15e0-8d30-4d56-b28a-7d92a99e7d6c@googlegroups.com>
Content-Type text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding 7bit
X-Provags-ID V02:K0:JjGjfbqYiM2In3YvYGXdrUEghcRSe3HPLIIMFVy4aL8 pfjHDtX01fKJDcLr/gsXweFofQcx7kMNIPP4ekEmVqJD5sHFSS WDeX44Zoak31TGrv79G5Oqd2ga3VoiHJBeZcZbwQX5/ivlHBhu H29YQqjr6rwGhYl9SqaYcJ1ztkBgIgv3z4NO5uHNH5f9k3LjPM f2+M1x0YE9eM50qjS/zjOZxQc2GhQbNXL9vhVcAOaSnvRo90bq XyqFQ8zCPD8Sw6HdFbRr3ovvmQM1uet9GqGutk1OpEbfauxPiE ytexXhPjaJJv7qrq88mxTsCr7Woc4KyEytYzaEY+I7/Qx5Ahix IsfnqZA6gRMlsjrdmKdM=
X-UI-Out-Filterresults notjunk:1;
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.15
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <https://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list/>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <https://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.18572.1423506358.18130.python-list@python.org> (permalink)
Lines 61
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1423506358 news.xs4all.nl 2837 [2001:888:2000:d::a6]:35935
X-Complaints-To abuse@xs4all.nl
Xref csiph.com comp.lang.python:85391

Show key headers only | View raw


On 02/09/2015 01:08 PM, John Ladasky wrote:
> On Monday, February 9, 2015 at 9:44:16 AM UTC-8, chim...@gmail.com wrote:
>> Hello. Am trying to change the key words to my tribal language. Eg change English language: print() to igbo language: de(). I have been stuck for months I need a mentor or someone that can guide me and answer some of my questions when I get stuck. Thanks..
>> I will really appreciate it if someone attends to me.
>
>
> In Python, functions are bound to names, exactly like other variables are.  You can bind any new name you want to an existing function, like this:
>
> Python 3.4.0 (default, Apr 11 2014, 13:05:11)
> [GCC 4.8.2] on linux
> Type "help", "copyright", "credits" or "license" for more information.
>>>> print("English")
> English
>>>> de = print
>>>> de("Igbo")
> Igbo
>>>> print("Both function names work")
> Both function names work
>>>> de("Both function names work")
> Both function names work
>
>
> Hope that helps you.
>

That will help him with the functions.  But not with the keywords.  The 
OP didn't specify Python version, but in 3.x, print() is a function, and 
can be rebound.  Since he said keyword, he's either mistaken, or he's 
running 2.x

But any real keywords, are a real problem.  For example, changing 'if' 
to some other string.

And all the library code is a problem, as they have to be individually 
translated.  And many of them are not fully in Python, but have C portions.

Then there's the return strings for exceptions, and file names for imports.

And the documentation, and the inline documentation, and reflection.

Many problems, no good solutions.  It has been considered many times by 
many good Python developers, and no reasonable solution has presented 
itself.

When I use grep at the bash command line, do I want these translated to 
English words.  Nope.  They both are acronyms, but few people know what 
they actually stand for.

I wish there were an answer, but I don't think so, other than using a 
non-language (like Esperanto) to pick all the keywords and library 
functions of a new language in.  Then that new language would be equally 
hard for all nationalities to learn.

http://legacy.python.org/workshops/1997-10/proceedings/loewis.html

http://grokbase.com/t/python/python-list/09bsr7hjwh/python-statements-keyword-localization



-- 
DaveA

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Please help. chimex60@gmail.com - 2015-02-09 18:43 +0100
  Re: Please help. John Ladasky <john_ladasky@sbcglobal.net> - 2015-02-09 10:08 -0800
    Re: Please help. Dave Angel <d@davea.name> - 2015-02-09 13:25 -0500
      Re: Please help. John Ladasky <john_ladasky@sbcglobal.net> - 2015-02-09 11:06 -0800
  Re: Please help. Steven D'Aprano <steve+comp.lang.python@pearwood.info> - 2015-02-10 10:59 +1100

csiph-web