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 | 3985 |
2 | jiangly | 3814 |
3 | jqdai0815 | 3682 |
4 | Benq | 3529 |
5 | orzdevinwang | 3526 |
6 | ksun48 | 3517 |
7 | Radewoosh | 3410 |
8 | hos.lyric | 3399 |
9 | ecnerwala | 3392 |
9 | Um_nik | 3392 |
# | User | Contrib. |
---|---|---|
1 | cry | 169 |
2 | maomao90 | 162 |
2 | Um_nik | 162 |
4 | atcoder_official | 161 |
5 | djm03178 | 158 |
6 | -is-this-fft- | 157 |
7 | adamant | 155 |
8 | awoo | 154 |
8 | Dominater069 | 154 |
10 | luogu_official | 150 |
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 |
---|