Algo. Running sum
Task
Given an array nums. We define a running sum of an array as runningSum[i] = sum(nums[0]…nums[i]). Return the running sum of nums. Example 1:
Task
Given an array nums. We define a running sum of an array as runningSum[i] = sum(nums[0]…nums[i]). Return the running sum of nums. Example 1:
margin
border
padding
content
margins by horizontal added, by vertical joined
BLOCK AND ELEMENT
Blocks can be inside blocks infinite times
<div class = «block»> <div class = «block__element»> </div> <div class = «anotherBlockInside»> <div class
.myClassLeft { float: left width: 33 % } .myClassRight { float: right width: 33 % } myClassNone { float: none }
to display on different devices
WHEN CONNECT CSS FILES
<link href=»css/small.css» rel=»stylesheet» media=»(max-width:480px)»> <link href=»css/large.css» rel=»stylesheet» media=»(min-width:769px)»> <link href=»css/medium.css» rel=»stylesheet» media=»(min-width:481px) and (max-width:768px)»> // import
@font-face to define style in css
// color
color: rgb(100%,100%,100%); color: rgb(255,255,255); color: rgba(255, 100, 50, .5); // last param is transperency, from 0 to
reset.css
html, body, div, span, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn,
p {} 1 point, simple tag selector .myClass {} 10 point .myId {} 100 points <div style = «text-align: center»></ div> 1000 points
Lets say
styles are inherited. for ex. <p> inside <body> inherits styles of <body>
body { font-family: Arial, Helvetica, sans-serif; } // this will be inherited for
HTML5 is contemporary format. (HTML 4.01 <br>, xHTML <br />, HTML supports both).
HTML5 brings new tags like <header>, <footer>, also tags for audio and