Nyob hauv computer science, ib tug literal yog a sau rau sawv cev tus nqi tas rau hauv qhov chaws. … Hauv qhov sib piv rau cov ntawv sau, qhov sib txawv lossis qhov tsis tu ncua yog cov cim uas tuaj yeem coj mus rau ib chav ntawm cov nqi ruaj khov, qhov tsis tu ncua raug txwv tsis pub hloov pauv.
Yam muab piv txwv li cas?
Ib tsab ntawv tuaj yeem yog tus lej, tus cim, lossis kab. Piv txwv li, hauv kab lus, x=3 . x yog qhov sib txawv, thiab 3 yog qhov tseeb.
Dab tsi yog qhov tseeb hauv C piv txwv?
Dab tsi yog cov ntawv nyeem? Cov ntawv nyeem yog tus nqi tas li muab rau cov hloov pauv tas mus li. Peb tuaj yeem hais tias cov ntawv sau sawv cev rau cov nqi ruaj khov uas tsis tuaj yeem hloov kho. … Piv txwv li, const int=10; yog ib qho integer qhia nyob rau hauv uas 10 yog integer literal.
koj txhais li cas ntawm kev hais lus?
true to fact; tsis exaggerated; qhov tseeb lossis qhov tseeb: qhov kev piav qhia ntawm cov xwm txheej. ua tau li ntawd, tsis muaj exaggeration los yog tsis raug: lub literal extermination ntawm ib lub nroog. (ntawm cov neeg) nyiam los txhais cov lus nyob rau hauv lub siab nruj los yog nyob rau hauv ib txoj kev unimaginative; teeb meem ntawm qhov tseeb; prosaic.
Python yog dab tsi?
A literal yog succinct thiab yooj yim pom txoj kev los sau tus nqi. Literals sawv cev rau cov kev xaiv uas muaj nyob rau hauv hom primitive rau hom lus ntawd. Qee qhov kev xaiv ntawm cov ntawv nyeem feem ntau yog cov lej, ntab taw tes, Booleans thiab cov hlua cim.