這裏有一則有趣的,我的團隊成員只是具有約稍微激烈的討論代碼... Dim fred As Integer
If True Then fred = 5 : fred = 3 : fred = 6 Else fred = 4 : fred = 2 : fred = 1
執行上面的代碼片段後,有什麼價值fred? 儘量不要欺騙和調試代碼。 這是一個非常有代表性的代碼示例,最初作爲使用冒號
我需要一個函數來選擇具有自定義屬性的所有元素,並採用它的名稱和值。例如: <input type="text" my:name="koni" my:age="20" my:city="New York" />
請注意,我是永遠不變的,但背後沒有。在我的函數然後我想說: var attr = //here should be the attribute (attr, or attr2)
和