본문 바로가기

Programming

(45)
Aracade Intro #31 depositProfit. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Aracade Intro #31 depositProfit. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Q. You have deposited a specific amount of money into your bank account. Each year your balance increases at the same growth rate. With the assumption that you don't make any additional deposits, find out how long it would take for your balance to pass a specific threshold. Of ..
Aracade Intro #30 circleOfNumbers. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Aracade Intro #30 circleOfNumbers. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Q. Consider integer numbers from 0 to n - 1 written down along the circle in such a way that the distance between any two neighboring numbers is equal (note that 0 and n - 1 are neighboring, too). Given n and firstNumber, find the number which is written in the radially oppos..
C++ How to convert string to integer in C++, string 에서 int 변환하는 방법, Easiest way to convert string to int. C++ How to convert string to integer in C++, string 에서 int 변환하는 방법, Easiest way to convert string to int. 반대로 바꾸는 함수는 아래에 링크로 가보세요~ ~ integer to string function ( Here ) c++ string 자료형에서 integer 으로 string형 숫자를 integer 로 저장 문제풀이 연습하는 사이트 같은데서는 c++을 주로 쓰는데 만이 쓰지만 항상 까먹어서 적어둠 I use sometimes this method, especially in codefights or leetcode when i'm using c++.. always confusing. Code.. lemme see co..
Aracade Intro #29 chessBoardCellColor. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Aracade Intro #29 chessBoardCellColor. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Q. Given two cells on the standard chess board, determine whether they have the same color or not. 체스판에서 주어진 두개의 셀이, 같은 색깔인지 아닌지 확인하라. e.g. For cell1 = "A1" and cell2 = "C3", the output should bechessBoardCellColor(cell1, cell2) = true. For cell1 = "A1" and cell2 = "H3", ..
OpenCV Java/C++ FourierFastTransferShift(fftshift) 푸리에 변환 후 위치 재설정 함수 (Matlab - fftshift) - (2) OpenCV Java/C++ FourierFastTransferShift(fftshift) 푸리에 변환 후 위치 재설정 함수 (Matlab - fftshift) - (2) I posted circShift method(below) what i coded few days ago, but it's new code using OpenCV core function a lot. Reference ( Here ) 2018/10/02 - [Programming/Image Processing] - OpenCV Java/C++ FourierFastTransferShift(fftshift) 푸리에 변환 후 위치 재설정 함수 (Matlab - fftshift) - (1) Performance that i coded this..
Aracade Intro #28 alphabeticShift. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Aracade Intro #28 alphabeticShift. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Q. Given a string, replace each its character by the next one in the English alphabet (z would be replaced by a). (Lowercase alphabet only) 주어진 문자열에서, 각 알파벳을 그 다음 알파벳으로 바꾸어라 ( a->b, c->d ) z 의 경우에는 다시 a 로 돌아간다. (전부 소문자 알파벳) e.g. Input -> inputString = "crazy" Output -> alphab..
Aracade Intro #27 variableName. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Aracade Intro #27 variableName. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Q. Correct variable names consist only of English letters, digits and underscores and they can't start with a digit. Check if the given string is a correct variable name. 변수명으로 옳은 것은 알파벳, 숫자, 언더바로만 이루어져 있고, 시작은 숫자로 할 수 없다.옳은 변수명인지 확인하라. e.g. For name = "var_1__Int", the output s..
Aracade Intro #26 evenDigitsOnly. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Aracade Intro #26 evenDigitsOnly. Algorithm, 알고리즘, Codefights, CodeSignal, 코드파이트, 코드시그널, 예제, example, c++ java c# scalar Q. Check if all digits of the given integer are even. 모든 자릿수 숫자가 짝수인지 확인하라 e.g. Input -> n = 248622 Output -> evenDigitsOnly(n) = true Input -> n = 642386 Output -> evenDigitsOnly(n) = false //처리과정//1. 정수를 입력받는다.//2. 정수의 자릿수 시작부터 끝까지 반복한다.// 2.1. 숫자가 짝수인지 확인한다.//3. 결과를 리턴한다. /..