optimization tag

10 questions


1 answers
120 views
0
&&& What is doing?

If you compile the code below into the gcc -Wall /-Waddress option,warning: the address of ‘i’ will always evaluate as ‘true’ [-Waddress]It appears.I don't know why it's coming up. I don't know what i...


1 answers
151 views
0
I'd like to share all the lists

L = [[[1, 2, 3], [4, 5]], 6]If the element in the list is a list like this [1, 2, 3, 4, 5, 6]I'm going to release all the elements of the list together.The way I know it, the list is[[1,2], [3,4], 5] ...


1 answers
107 views
0
GCC does not optimize a*a*a*a*a*a to (a*a*a)*(a*a*a).

As far as I know, the compiler optimizes power(a,2) to a*apow(a,6) does not optimize, but calls the library function pow().The C++ Intel Compiler optimizes you to 6Why does the GCC C compiler optimize...


1 answers
97 views
0
The debug mode and the release mode are different. Why?

The chords are weird.Visual Studio 2008 is developing it, but why will it be different when it is debugged and released? int _tmain(int argc, _TCHAR* argv[]){ for( int i = 0; i < 17; i++ ) { int...


1 answers
111 views
0
Search Optimization (SEO) Questions

When you say you're building a community site, what's the way to make it easily exposed to search engines?Among the methods I know,The way it doesn't cost isRegister a site meta tagRegistering with se...


1 answers
99 views
0
I'd like to break up the list elements into four pieces and approach them

You want to split four elements into a list that stores only integers.Right now, it's just i+1, i+2,... Is there any other way?It hasn't been long since I came over from C, so I keep coming up with th...


1 answers
109 views
0
Do I have to write import on the top line of the code?

Usually, when importing modules, they seem to put them in the top row like Source Code 2 rather than Source Code 1. I don't think you need to import it to the top row if it's a module that's only used...


1 answers
75 views
0
Which is the better way to divide an integer by 2?

Which one is better between the two methods below? Please write down the reason, tooint x = 3;x = x >> 1;x = x / 2;

1 years ago

1 answers
126 views
0
Which is faster, "for(;)" or "while(TRUE)?

[Which is faster, (1) or (2)?I thought of this while looking at for (;;) { //Something to be done repeatedly}I've seen a lot of codes like this, but I haven't seen them write in while(true).I think wh...


1 answers
101 views
0
Is strlen() calculated every time in the for statement?

for (int i = 0; i < strlen(ss); ++i){ // Hello}If you think about it, the ss might change inside the for statementI think strlen(ss) should be calculated every timeBut if you do strlen() every time...

1 years ago

© 2024 OneMinuteCode. All rights reserved.