폰트 사이즈 5씩 증가
페이지 정보
본문
ex) for 문으로 10px ~ 35px 크기 출력(5px 증가)
<script>
for(var size=10; size<=35; size+=5){
document.write("<span ");
document.write("style = 'font-size:" + size + "px'>");
document.write(size + "px");
document.write("</span> ");
}
</script>
추천0 비추천0
- 이전글▶ 반복문 - for() 21.07.16
- 다음글1~10 중에 3으로 나눈 나머지 값이 1인 수를 출력,합계 - ( continue 이용 ) 21.07.16
댓글목록
등록된 댓글이 없습니다.