How to find number of values x which achieve GCD(n, x) = 1
n is constant
x <= m
m can be bigger than n
the related problem to this question that I am trying to solve:
# | User | Rating |
---|---|---|
1 | tourist | 4009 |
2 | jiangly | 3823 |
3 | Benq | 3738 |
4 | Radewoosh | 3633 |
5 | jqdai0815 | 3620 |
6 | orzdevinwang | 3529 |
7 | ecnerwala | 3446 |
8 | Um_nik | 3396 |
9 | ksun48 | 3390 |
10 | gamegame | 3386 |
# | User | Contrib. |
---|---|---|
1 | cry | 167 |
2 | Um_nik | 163 |
3 | maomao90 | 162 |
3 | atcoder_official | 162 |
5 | adamant | 159 |
6 | -is-this-fft- | 158 |
7 | awoo | 157 |
8 | TheScrasse | 154 |
9 | Dominater069 | 153 |
9 | nor | 153 |
How to find number of values x which achieve GCD(n, x) = 1
n is constant
x <= m
m can be bigger than n
the related problem to this question that I am trying to solve:
If I have a Program.exe that takes input and print it.
If I want to run this program from the cmd I will go to its directory and write Program.exe (enter).
And what is going to happen a new line and waiting for the input.
But what if I want to give the input at the same line like that :
c:\Users\abc> Program.exe input
and that's it the program doesn't ask for input(as I gave it at the same line when I invoked the program) and print the output and terminate
I am working with c++.
AT this problem https://codeforces.net/gym/102470/problem/A (short statment below)
after three days of coding to avoid runtime error I get TLE on a binary search solution can someone explain what is wrong with my solution
the short statement : You are given set of points (x,y) find point on (y = 0) which all point can go to this point in minimum time and all have the same speed which is one meter per second
my code : https://codeforces.net/contest/1445/submission/98270485 (the code has comments :)
I really want to know how to solve this problem :
You are given two positive integers d and s. Find minimal positive integer n which is divisible by d and has sum of digits equal to s.
If I am calling too many functions which is more than allowed in the memory limit I will get run time error or memory limit exceeded ? like in this code https://codeforces.net/contest/1067/submission/85187079
UPD If I am calling too many functions which is more than the stack size I will get run time error or memory limit exceeded ?
Can someone provide a tutorial on how to use prefix sum with dynamic programming ?
Given a string consist just of the letter 'u' ,if we can consider every two adjacent 'u' -->' w' and every u can be used only once in how many ways the string can appear ?
example : uuu can be uuu or wu or u w so the answer is 3 .
I am asking this question because at the last contest I was trying to solve this problem https://codeforces.net/contest/1245/problem/C and I claim the solution is every continuous 'u' or 'n' I save in how many ways it can appear in a vector and then multiply all the numbers and this is the answer .
Name |
---|