Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #58504
| From | Dave Angel <davea@davea.name> |
|---|---|
| Subject | Re: how to find out utf or not |
| Date | 2013-11-05 08:41 -0600 |
| References | <1383656577.1350.6.camel@debian> <1383656577.1350.6.camel@debian> |
| Newsgroups | comp.lang.python |
| Message-ID | <mailman.2055.1383662485.18130.python-list@python.org> (permalink) |
On Tue, 05 Nov 2013 16:32:57 +0330, Mohsen Pahlevanzadeh <mohsen@pahlevanzadeh.org> wrote: > Suppose i have a variable such as : myVar = 'x' > May be it initialized with myVar = u'x' or myVar = 'x' > So i need determine content of myVar that it's utf-8 or not, how can i > do it? Use the type() function and compare to unicode or str respectively. E.g. If type(myvar)==unicode: -- DaveA
Back to comp.lang.python | Previous | Next — Next in thread | Find similar | Unroll thread
Re: how to find out utf or not Dave Angel <davea@davea.name> - 2013-11-05 08:41 -0600
Re: how to find out utf or not Neil Cerutti <neilc@norwich.edu> - 2013-11-05 15:30 +0000
Re: how to find out utf or not Dave Angel <davea@davea.name> - 2013-11-06 00:03 -0600
csiph-web