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


Groups > de.comp.lang.python > #5646

Re: f-string Formatanweisung

Path csiph.com!weretis.net!feeder7.news.weretis.net!news.mb-net.net!open-news-network.org!.POSTED.2003:a:e6c:ab01:a5e8:beff:920c:ff8a!not-for-mail
From "Andreas B." <ab@sysing.de>
Newsgroups de.comp.lang.python
Subject Re: f-string Formatanweisung
Date Mon, 22 Jun 2020 15:03:24 +0200
Organization MB-NET.NET for Open-News-Network e.V.
Message-ID <rcqa6s$u49$1@gwaiyur.mb-net.net> (permalink)
References <rcq1j2$5b5$1@dont-email.me>
Mime-Version 1.0
Content-Type text/plain; charset=iso-8859-15; format=flowed
Content-Transfer-Encoding 8bit
Injection-Date Mon, 22 Jun 2020 13:03:24 -0000 (UTC)
Injection-Info gwaiyur.mb-net.net; posting-host="2003:a:e6c:ab01:a5e8:beff:920c:ff8a"; logging-data="30857"; mail-complaints-to="abuse@open-news-network.org"
User-Agent Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.9.0
Cancel-Lock sha1:SyafGui/DR0kfsxmCOmGPZY/j3M=
In-Reply-To <rcq1j2$5b5$1@dont-email.me>
Content-Language de-DE
X-User-ID U2FsdGVkX19uioREhsHCXyEQtjWxx4CHQW8wFEes0aI=
Xref csiph.com de.comp.lang.python:5646

Show key headers only | View raw


Am 22.06.2020 um 12:36 schrieb ruppert@hs-worms.de:
> das unten befindliche Programm funktioniert mit f-String-Formatierung
> nicht so, wie ich das erwarte. Wenn ich das F-String-Format, das ich
> haben möchte, zuerst als Striing formatiere (s), sieht es richtig aus.
> 
> Aber bei print(s) wird nicht das in s steckende f-string-Format
> interpretiert, sonde

...

> #!/usr/bin/python3
> import sys
> if(len(sys.argv)<2):
...

Ähm, welches /usr/bin/python3? die F-Strings gibt es erst seit Python 
3.6. Läuft da vielleicht ein älteres Dreier-Python?

Grüße,
  A.B.

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


Thread

f-string Formatanweisung ruppert@hs-worms.de - 2020-06-22 10:36 +0000
  Re: [Python-de] f-string Formatanweisung Mike Müller <mmueller@python-academy.de> - 2020-06-22 14:27 +0200
  Re: [Python-de] f-string Formatanweisung Mike Müller <mmueller@python-academy.de> - 2020-06-22 14:31 +0200
    Re: [Python-de] f-string Formatanweisung ruppert@hs-worms.de - 2020-06-22 13:22 +0000
  Re: [Python-de] f-string Formatanweisung Stefan Behnel <python-de@behnel.de> - 2020-06-22 14:55 +0200
  Re: f-string Formatanweisung "Andreas B." <ab@sysing.de> - 2020-06-22 15:03 +0200
    Re: f-string Formatanweisung ruppert@hs-worms.de - 2020-06-22 13:28 +0000
  Re: [Python-de] f-string Formatanweisung Stefan Behnel <python-de@behnel.de> - 2020-06-22 15:14 +0200
    Re: [Python-de] f-string Formatanweisung ruppert@hs-worms.de - 2020-06-22 14:03 +0000
    Re: [Python-de] f-string Formatanweisung ruppert@hs-worms.de - 2020-07-13 11:13 +0000

csiph-web