반응형
250x250
Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- 무협
- 객관식 경영학 정오표
- 2024 부산교통공사 면접
- 강웅
- 아비무쌍
- 금강마신
- sas base
- 토르마무
- 노경찬
- 김윤상
- 에듀윌특별판
- 부교공
- 아비무쌍 #오존
- 에듀윌 봉모
- 부교공 면접
- 객경
- 신입사원 채용
- 코레일
- 김윤상 객경 정오표
- 객관식 경영학
- 산업인력공단 #산인공 #ncs #모듈형 #정오표
- 천소소
- 모듈형 #산인공 #산업인력공단 #ncs #예시문제 #해설
- 부산교통공사
Archives
- Today
- Total
나루다루
SAS BASE Q6. trim & || [수정] 본문
728x90
반응형
QUESTION NO: 6
Given the raw data record DEPT:
----|----10----|----20---|----30
Printing 750
The following SAS program is submitted:
data bonus;
infile 'dept';
input dept $ 1-11 number 13-15;
<insert statement here>
run;
Which SAS statement completes the program and results in a value of 'Printing750' for the DEPARTMENT variable?
A. department = dept || number;
B. department = left(dept) || number;
C. department = trim(dept) || number;
D. department = trim(dept) || put(number,3.);
Answer: D
# 문제 수정
- 각 보기에 || 추가 및 수정
# 문제 풀이
- input dept $ 1-11 : 데이터 'dept'의 1~11번째 자리를 변수 dept에 저장함
- trim(변수) : 변수 내의 공백 제거
- || : 문자와 문자를 연결
- input(변수,길이.) : 문자형을 숫자형으로 변환
- put(변수,길이.) : 숫자형을 문자형으로 변환
728x90
반응형
'Study > SAS BASE' 카테고리의 다른 글
SAS BASE Q8. do until & gt (0) | 2018.02.12 |
---|---|
SAS BASE Q7. tranwrd (0) | 2018.02.12 |
SAS BASE Q5. footnote (0) | 2018.02.11 |
SAS BASE Q4. if & output [수정] / 15,20번과 비교 (1) | 2018.02.11 |
SAS BASE Q3. length 구문 (0) | 2018.02.11 |
Comments