format tag

9 questions


1 answers
134 views
0
I want to change it to a string without any unnecessary parts such as zero below the decimal point when I print out the real number, what should I do?

On 64-bit operating systems, double represents up to +-253. Until 53I'm using double because I think the size of the number I'm expressing is about unsigned 32-bit Integer. The problem is that even if...


1 answers
89 views
0
Type specifier %i, %d difference

I know that you can use both the format specifiers %i and %d when printing integers. What's the difference between you two? Did you make it separately?

2 years ago

1 answers
106 views
0
How do I take a comma in a thousand digits in JavaScript?

I'd like to take a comma in a thousand digits when I print the integrer in JavaScript. For example,If you have 1234567, I want to print it out like 1,234,567 function numberWithCommas(x) { x = x.toStr...

2 years ago

1 answers
96 views
0
I am trying to change the date format using python datetime.strptime, but a Value Error appears.

The data I want to format is date data in the format [20160610]T[0].Bring to repeat statement Use datetime.strptime to make that data into a single string like '%sT%s' The format is [%Y%m%d]T[%H%M%S]....


1 answers
136 views
0
Type specifier for double in printf

How should I write the format specifier for double in printf?Is it correct to use %f or %lf?#include <stdio.h>int main(){ double d =1.4; printf(%lf, d); //is this wrong?}

2 years ago

1 answers
154 views
0
How do I get the date and time on Android?

I'd like to receive the date and time set on the device with the code, so what can I do?


2 answers
121 views
0
Use format function for Python class

I'm going to pre-define the function in the class and import it at any time to use it.The desired output value is m1: How is your relationship going? g1 ah?def romance(self, listener): print({}): How'...

2 years ago

1 answers
68 views
0
Print Braces {}

I want to print {} how do I write it?There's an error in the way I wrote itI want to print it out like {Hello} 42.Key Error: Hello\\x = \{ Hello \} {0} print x.format(42)

2 years ago

2 answers
79 views
0
format sorting

I'm curious about the role of a,b when we say {a:bd}.When you say {a:b.cf}I'm curious about the role of a.Thank you for your answer Have a great day!

2 years ago

© 2024 OneMinuteCode. All rights reserved.