C語言位運算符與或異或取反左移和右移_第1頁
C語言位運算符與或異或取反左移和右移_第2頁
C語言位運算符與或異或取反左移和右移_第3頁
C語言位運算符與或異或取反左移和右移_第4頁
C語言位運算符與或異或取反左移和右移_第5頁
已閱讀5頁,還剩15頁未讀, 繼續(xù)免費閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進行舉報或認領(lǐng)

文檔簡介

C&1,則該位的成果值為1,否則為0|按位或兩個對應的二進制位中只要有一種為1,該位的成果值為1^按位異或若參加運算的兩個二進制位值相似則為0,否則為1~取反~是一元運算符,用來對一種二進制數(shù)按位取反,即將0變1,將1變0按位與是指:參加運算的兩個數(shù)據(jù),按二進制位進行“與”運算。如果兩個對應的二進制位都為,,則該位的成果值為1;否則為0。這里的1能夠理解為邏輯中的rue,0能夠理解為邏輯中的false輯上的“與”,規(guī)定運算數(shù)全真,成果才為真。若,A=true,B=true,則A?B=true例如:3&5的數(shù)據(jù)均在數(shù)據(jù)背面加上括號,括號中注明其進制,二進制則標記為2)installationpartmainincludingYunnanprovincetengchongCountyyongxingRiverprimaryandsecondaryhydropowerstationintheofpressurepipeandthepowerstationmetalstructure,whichlevelpowerstationpressurepipetotalabout562t(containingannex);IIlevelpowerstationpressurepipeabout733t(containingannex);levelpowerstationmetalstructureabout52.5t,containingdischargeGate2hole,rushedsandGate1hole,watermouthworkdoorandthestoppeddirtgatethe1hole,Qianpoolworkdoorandthestoppeddirtgatethe1hole;Secondarypowerstationmetaljunctionatabout19.5t,containingsandGate1hole,waterinletwatergateandtrashthe1hole;theirauxiliaryhoistequipmentandelectricalequipment.Concretepressurepipe,gate,trashandhoistingdeviceprojectpropertylist1-1~1-3.Table1-1themaincharacteristicsofthepenstocknumberitemparametertypecontrollersizeheadalongpipediameterpipelength11hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.3M931m0.8M8.3*2m22hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.4m1063.506m0.8M10*2mtable1-2hydropowerstationMaincharacteristicsofhydraulicmetalstructurenumberprojectnamegate,trashrack,door(gate...Pressurepipeandthemetalstructureinstallation9.1mainengineeringprofileyongxingriverlevelhydropowerstationpressurepipepipelineplaneShangalongRidgeislinelayout,andslopesurfacecontourclosevertical,GuanPowithoriginalgroundlinechanges,usedopentypeMingtube,singletubejointwaterway,competentdiameter1.3M,long931.00m,tworootnon-symmetric"Bu"typesupporttube,diameter0.8M,singlerootlong8.3M.Competenttoestablish12townPier,107buttress,telescopicsection11.SupportPierspacing8M,side-slidingbearing.Townpierfortheclosed-endstructureofgravity,basesurfaceintobedrock,pipeexcavationslope1:0.75withM5groutedrubbleslopeprotection,0.3M,bottomsidesewer,0.25mwide,deep0.3m,M5groutedrubblemasonry,setmaintenancestepladderontheleftside,1.0Mwide.Yongxinghe-?hydropowerstationpenstockpipesarrangedalongtheridgelineontheplane,andnearlyverticalslopecontourlines,GuanPochangeswiththeoriginalgroundline,withshallowbackfill-pipe,single-pipewatersupply,thecompetent1.4m,long1063.506m,twoasymmetric"y"pipe,diameter0.8M,single10m.Competenttoestablish12townPier,8expansionjoint.Townpierfortheclosed-endstructureofgravity,placedonsoftrockbasesurface,pipeconcreteC20onapedestal.Pipetrenchexcavationslope1:0.75,aftertheinstallationofsteeltube,compactedgravel#include<stdio.h>{inta=3;intb=5;printf("%d",a&b);若想對一種存儲單元清零,即使其全部二進制位為0,其原來的數(shù)中為1的位,新數(shù)中對應位為0。然后使兩者進行&零c#include<stdio.h>{intintb=printf("%d",a&b);installationpartmainincludingYunnanprovincetengchongCountyyongxingRiverprimaryandsecondaryhydropowerstationintheofpressurepipeandthepowerstationmetalstructure,whichlevelpowerstationpressurepipetotalabout562t(containingannex);IIlevelpowerstationpressurepipeabout733t(containingannex);levelpowerstationmetalstructureabout52.5t,containingdischargeGate2hole,rushedsandGate1hole,watermouthworkdoorandthestoppeddirtgatethe1hole,Qianpoolworkdoorandthestoppeddirtgatethe1hole;Secondarypowerstationmetaljunctionatabout19.5t,containingsandGate1hole,waterinletwatergateandtrashthe1hole;theirauxiliaryhoistequipmentandelectricalequipment.Concretepressurepipe,gate,trashandhoistingdeviceprojectpropertylist1-1~1-3.Table1-1themaincharacteristicsofthepenstocknumberitemparametertypecontrollersizeheadalongpipediameterpipelength11hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.3M931m0.8M8.3*2m22hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.4m1063.506m0.8M10*2mtable1-2hydropowerstationMaincharacteristicsofhydraulicmetalstructurenumberprojectnamegate,trashrack,door(gate...Pressurepipeandthemetalstructureinstallation9.1mainengineeringprofileyongxingriverlevelhydropowerstationpressurepipepipelineplaneShangalongRidgeislinelayout,andslopesurfacecontourclosevertical,GuanPowithoriginalgroundlinechanges,usedopentypetube,singletubejointwaterway,competentdiameter1.3M,long931.00m,tworootnon-symmetric"Bu"typesupporttube,diameter0.8M,singlerootlong8.3M.Competenttoestablish12townPier,107buttress,telescopicsection11.SupportPierspacing8M,side-slidingbearing.Townpierfortheclosed-endstructureofgravity,basesurfaceintobedrock,pipeexcavationslope1:0.75withM5groutedrubbleslopeprotection,0.3M,bottomsidesewer,0.25mwide,deep0.3m,M5groutedrubblemasonry,setmaintenancestepladderontheleftside,1.0Mwide.Yongxinghe-?hydropowerstationpenstockpipesarrangedalongtheridgelineontheplane,andnearlyverticalslopecontourlines,GuanPochangeswiththeoriginalgroundline,withshallowbackfill-pipe,single-pipewatersupply,thecompetent1.4m,long1063.506m,twoasymmetric"y"pipe,diameter0.8M,single10m.Competenttoestablish12townPier,8expansionjoint.Townpierfortheclosed-endstructureofgravity,placedonsoftrockbasesurface,pipeconcreteC20onapedestal.Pipetrenchexcavationslope1:0.75,aftertheinstallationofsteeltube,compactedgravel}若有一種整數(shù)a(2byte),想要取其中的低字節(jié),只需要將a與8個1abc與一種數(shù)進行“按位與”運算,此數(shù)在該位取例如:有一數(shù)84,即01010100(2),想把其中從左邊算起的第8即c#include<stdio.h>{inta=84;intb=59;}2、“按位或”運算符o例如:60(8)|17(8),將八進制60與八進制17進行按位或運算。installationpartmainincludingYunnanprovincetengchongCountyyongxingRiverprimaryandsecondaryhydropowerstationintheofpressurepipeandthepowerstationmetalstructure,whichlevelpowerstationpressurepipetotalabout562t(containingannex);IIlevelpowerstationpressurepipeabout733t(containingannex);levelpowerstationmetalstructureabout52.5t,containingdischargeGate2hole,rushedsandGate1hole,watermouthworkdoorandthestoppeddirtgatethe1hole,Qianpoolworkdoorandthestoppeddirtgatethe1hole;Secondarypowerstationmetaljunctionatabout19.5t,containingsandGate1hole,waterinletwatergateandtrashthe1hole;theirauxiliaryhoistequipmentandelectricalequipment.Concretepressurepipe,gate,trashandhoistingdeviceprojectpropertylist1-1~1-3.Table1-1themaincharacteristicsofthepenstocknumberitemparametertypecontrollersizeheadalongpipediameterpipelength11hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.3M931m0.8M8.3*2m22hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.4m1063.506m0.8M10*2mtable1-2hydropowerstationMaincharacteristicsofhydraulicmetalstructurenumberprojectnamegate,trashrack,door(gate...Pressurepipeandthemetalstructureinstallation9.1mainengineeringprofileyongxingriverlevelhydropowerstationpressurepipepipelineplaneShangalongRidgeislinelayout,andslopesurfacecontourclosevertical,GuanPowithoriginalgroundlinechanges,usedopentypeMingtube,singletubejointwaterway,competentdiameter1.3M,long931.00m,tworootnon-symmetric"Bu"typesupporttube,diameter0.8M,singlerootlong8.3M.Competenttoestablish12townPier,107buttress,telescopicsection11.SupportPierspacing8M,side-slidingbearing.Townpierforclosed-endstructureofgravity,basesurfaceintobedrock,pipeexcavationslope1:0.75withM5groutedrubbleslopeprotection,0.3M,bottomsidesewer,0.25mwide,deep0.3m,M5groutedrubblemasonry,setmaintenancestepladderontheleftside,1.0Mwide.Yongxinghe-?hydropowerstationpenstockpipesarrangedalongtheridgelineontheplane,andnearlyverticalslopecontourlines,GuanPochangeswiththeoriginalgroundline,withshallowbackfill-pipe,single-pipewatersupply,thecompetent1.4m,long1063.506m,twoasymmetric"y"pipe,diameter0.8M,single10m.Competenttoestablish12townPier,8expansionjoint.Townpierfortheclosed-endstructureofgravity,placedonsoftrockbasesurface,pipeconcreteC20onapedestal.Pipetrenchexcavationslope1:0.75,aftertheinstallationofsteeltube,compactedgravelc#include<stdio.h>{inta=060;intb=017;}應用:按位或運算慣用來對一種數(shù)據(jù)的某些位定值為1。例如a的低4位改為1,則只需要將a與17(8)例如:,,,,即11(2);,,,,即100(2),,111(2)(a?b的成果,a,,011(2)(b?a的成果,b,,100(2)(a?b的成果,ainstallationpartmainincludingYunnanprovincetengchongCountyyongxingRiverprimaryandsecondaryhydropowerstationintheofpressurepipeandthepowerstationmetalstructure,whichlevelpowerstationpressurepipetotalabout562t(containingannex);IIlevelpowerstationpressurepipeabout733t(containingannex);levelpowerstationmetalstructureabout52.5t,containingdischargeGate2hole,rushedsandGate1hole,watermouthworkdoorandthestoppeddirtgatethe1hole,Qianpoolworkdoorandthestoppeddirtgatethe1hole;Secondarypowerstationmetaljunctionatabout19.5t,containingsandGate1hole,waterinletwatergateandtrashthe1hole;theirauxiliaryhoistequipmentandelectricalequipment.Concretepressurepipe,gate,trashandhoistingdeviceprojectpropertylist1-1~1-3.Table1-1themaincharacteristicsofthepenstocknumberitemparametertypecontrollersizeheadalongpipediameterpipelength11hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.3M931m0.8M8.3*2m22hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.4m1063.506m0.8M10*2mtable1-2hydropowerstationMaincharacteristicsofhydraulicmetalstructurenumberprojectnamegate,trashrack,door(gate...Pressurepipeandthemetalstructureinstallation9.1mainengineeringprofileyongxingriverlevelhydropowerstationpressurepipepipelineplaneShangalongRidgeislinelayout,andslopesurfacecontourclosevertical,GuanPowithoriginalgroundlinechanges,usedopentypeMingtube,singletubejointwaterway,competentdiameter1.3M,long931.00m,tworootnon-symmetric"Bu"typesupporttube,diameter0.8M,singlerootlong8.3M.Competenttoestablish12townPier,107buttress,telescopicsection11.SupportPierspacing8M,side-slidingbearing.Townpierfortheclosed-endstructureofgravity,basesurfaceintobedrock,pipeexcavationslope1:0.75withM5groutedrubbleslopeprotection,0.3M,bottomsidesewer,0.25mwide,deep0.3m,M5groutedrubblemasonry,setmaintenancestepladderontheleftside,1.0Mwide.Yongxinghe-?hydropowerstationpenstockpipesarrangedalongtheridgelineontheplane,andnearlyverticalslopecontourlines,GuanPochangeswiththeoriginalgroundline,withshallowbackfill-pipe,single-pipewatersupply,thecompetent1.4m,long1063.506m,twoasymmetric"y"pipe,diameter0.8M,single10m.Competenttoestablish12townPier,8expansionjoint.Townpierfortheclosed-endstructureofgravity,placedonsoftrockbasesurface,pipeconcreteC20onapedestal.Pipetrenchexcavationslope1:0.75,aftertheinstallationofsteeltube,compactedgravel?執(zhí)行前兩個賦值語句:“,,,?,;”和“,,,?,;”相稱于b=b?(a?b),,,?,。由于a的值等于(,?,),bc#include<stdio.h>{inta=3;intb=4;printf("a=%db=%d",a,b);1變?yōu)?,0變?yōu)?#include<stdio.h>{inta=077;installationpartmainincludingYunnanprovincetengchongCountyyongxingRiverprimaryandsecondaryhydropowerstationintheofpressurepipeandthepowerstationmetalstructure,whichlevelpowerstationpressurepipetotalabout562t(containingannex);IIlevelpowerstationpressurepipeabout733t(containingannex);levelpowerstationmetalstructureabout52.5t,containingdischargeGate2hole,rushedsandGate1hole,watermouthworkdoorandthestoppeddirtgatethe1hole,Qianpoolworkdoorandthestoppeddirtgatethe1hole;Secondarypowerstationmetaljunctionatabout19.5t,containingsandGate1hole,waterinletwatergateandtrashthe1hole;theirauxiliaryhoistequipmentandelectricalequipment.Concretepressurepipe,gate,trashandhoistingdeviceprojectpropertylist1-1~1-3.Table1-1themaincharacteristicsofthepenstocknumberitemparametertypecontrollersizeheadalongpipediameterpipelength11hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.3M931m0.8M8.3*2m22hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.4m1063.506m0.8M10*2mtable2hydropowerstationMaincharacteristicsofhydraulicmetalstructurenumberprojectnamegate,trashrack,door(gate...Pressurepipeandthemetalstructureinstallation9.1mainengineeringprofileyongxingriverlevelhydropowerstationpressurepipepipelineplaneShangalongRidgeislinelayout,andslopesurfacecontourclosevertical,GuanPowithoriginalgroundlinechanges,usedopentypeMingtube,singletubejointwaterway,competentdiameter1.3M,long931.00m,tworootnon-symmetric"Bu"typesupporttube,diameter0.8M,singlerootlong8.3M.Competenttoestablish12townPier,107buttress,telescopicsection11.SupportPierspacing8M,side-slidingbearing.Townpierfortheclosed-endstructureofgravity,basesurfaceintobedrock,pipeexcavationslope1:0.75withM5groutedrubbleslopeprotection,0.3M,bottomsidesewer,0.25mwide,deep0.3m,M5groutedrubblemasonry,setmaintenancestepladderontheleftside,1.0Mwide.Yongxinghe-?hydropowerstationpenstockpipesarrangedalongtheridgelineontheplane,andnearlyverticalslopecontourlines,GuanPochangeswiththeoriginalgroundline,withshallowbackfill-pipe,single-pipewatersupply,thecompetent1.4m,long1063.506m,twoasymmetric"y"pipe,diameter0.8M,single10m.Competenttoestablish12townPier,8expansionjoint.Townpierfortheclosed-endstructureofgravity,placedonsoftrockbasesurface,pipeconcreteC20onapedestal.Pipetrenchexcavationslope1:0.75,aftertheinstallationofsteeltube,compactedgravel}5值),其右邊空出的位用0位得00111100(2)#include<stdio.h>{inta=15;}左移1位相稱于該數(shù)乘以2,左移2位相稱于該數(shù)乘以2*2,4,15,,2=60,數(shù)左移時被溢出舍棄的高位中不包含1,而左移2位時,溢出的高位中包含16installationpartmainincludingYunnanprovincetengchongCountyyongxingRiverprimaryandsecondaryhydropowerstationintheofpressurepipeandthepowerstationmetalstructure,whichlevelpowerstationpressurepipetotalabout562t(containingannex);IIlevelpowerstationpressurepipeabout733t(containingannex);levelpowerstationmetalstructureabout52.5t,containingdischargeGate2hole,rushedsandGate1hole,watermouthworkdoorandthestoppeddirtgatethe1hole,Qianpoolworkdoorandthestoppeddirtgatethe1hole;Secondarypowerstationmetaljunctionatabout19.5t,containingsandGate1hole,waterinletwatergateandtrashthe1hole;theirauxiliaryhoistequipmentandelectricalequipment.Concretepressurepipe,gate,trashandhoistingdeviceprojectpropertylist1-1~1-3.Table1-1themaincharacteristicsofthepenstocknumberitemparametertypecontrollersizeheadalongpipediameterpipelength11hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.3M931m0.8M8.3*2m22hydropowerstationpenstockopen-airexposedpipe,singlepipejointwatersupply1.4m1063.506m0.8M10*2mtable1-2hydropowerstationMaincharacteristicsofhydraulicmetalstructurenumberprojectnamegate,trashrack,door(gate...Pressurepipeandthemetalstructureinstallation9.1mainengineeringprofileyongxingriverlevelhydropowerstationpressurepipepipelineplaneShangalongRidgeislinelayout,andslopesurfacecontourclosevertical,GuanPowithoriginalgroundlinechanges,usedopentypeMingtube,singletubejointwaterway,competentdiameter1.3M,long931.00m,tworootnon-symmetric"Bu"typesupporttube,diameter0.8M,singlerootlong8.3M.Competenttoestablish12townPier,107buttress,telescopicsection11.SupportPierspacing8M,side-slidingbearing.Townpierfortheclosed-endstructureofgravity,basesurfaceintobedrock,pipeexcavationslope1:0.75withM5groutedrubbleslopeprotection,0.3M,bottomsidesewer,0.25mwide,deep0.3m,M5groutedrubblemasonry,setmaintenancestepladderontheleftside,1.0Mwide.Yongxinghe-?hydropowerstationpenstockpipesarrangedalongtheridgelineontheplane,andnearlyverticalslopecontourlines,GuanPochangeswiththeoriginalgroundline,withshallowbackfill-pipe,single-pipewatersupply,thecompetent1.4m,long1063.506m,twoasymmetric"y"pipe,diameter0.8M,single10m.Competenttoestablish12townPier,8expansionjoint.Townpierfortheclosed-endstructureofgravity,placedonsoftrockbasesurface,pipeconcreteC20onapedestal.Pipetrenchexcavationslope1:0.75,aftertheinstallationofsteeltube,compactedgravel系統(tǒng)移入1。移入0的稱為“邏輯移位”,即簡樸移位;移入1a的值是八進制數(shù)113755:a:1101(用二進制形式表達)a>>1:0110(邏輯右移時)a>>1:0110在有些系統(tǒng)中,a>>1得八進制數(shù)045766,而在另某些系統(tǒng)上可能得到的是。TurboC和其它某些#include<stdio.h>{inta=0113755;}7例如:&=,|=,>>=,<<=,?=a&baa&ba<<=2相稱于a=a<<2installationpartmainincludingYunnanprovincetengchongCountyyongxingRiverprimaryandsecondaryhydropowerstationintheofpressurepipeandthepowerstationmetalstructure,whichlevelpowerstationpressurepipetotalabout562t(containingannex);IIlevelpowerstationpressurepipeabout733t(containingannex);levelpowerstationmetalstructureabout52.5t,containingdischargeGate2hole,rushedsandGate1hole,watermouthworkdoorandthestoppeddirtgatethe1hole,Qianpoolworkdoorandthestoppeddirtgatethe1hole;Secondarypowerstationmetaljunctionatabout19.5t,containingsandGate1hole,waterinletwatergateandtrashthe1h

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預覽,若沒有圖紙預覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負責。
  • 6. 下載文件中如有侵權(quán)或不適當內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準確性、安全性和完整性, 同時也不承擔用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

評論

0/150

提交評論