Morning buds

Sep 19, 2008
374,146
24,972
I cannot discord rn because I am busy trying to workon this python. But the dictionary is being stupid ! I'm pretty sure you can output an entire dictionary and not just one line. @Lunazaia Nox Fleuret or anyone with python experience please help !
 
Sep 19, 2008
374,146
24,972
# Four Fundamental Forces with JSON
d = {}
d ["gravity"] = {
"mediator":"gravitons",
"relative strength" : "1",
"range" : "infinity"
}
d ["weak"] = {
"mediator":"W/Z bosons",
"relative strength" : "10^25",
"range" : "10^-18"
}
d ["electromagnetic"] = {
"mediator":"photons",
"relative strength" : "10^36",
"range" : "infinity"
}
d ["strong"] = {
"mediator":"gluons",
"relative strength" : "10^38",
"range" : "10^-15"
}
import json
# encoding to JSON
data = json.dumps(d)
# write to a file
with open("4forces.json","w") as f:
f.write(data)
# reads it back
with open("4forces.json","r") as f:
data = f.read()
# decoding the JSON to dictionay
d = json.loads(data)
print(d)
 
Sep 19, 2008
374,146
24,972
json.dump(obj, fp, skipkeys=False, ensure_ascii=True, check_circular=True, allow_nan=True, cls=None, indent=None, separators=None, encoding="utf-8", default=None, sort_keys=False, **kw)
Serialize obj as a JSON formatted stream to fp (a .write()-supporting file-like object) using this conversion table.
If skipkeys is true (default: False), then dict keys that are not of a basic type (str, unicode, int, long, float, bool, None) will be skipped instead of raising a TypeError.
If ensure_ascii is true (the default), all non-ASCII characters in the output are escaped with \uXXXX sequences, and the result is a str instance consisting of ASCII characters only. If ensure_ascii is false, some chunks written to fp may be unicode instances. This usually happens because the input contains unicode strings or the encoding parameter is used. Unless fp.write() explicitly understands unicode (as in codecs.getwriter()) this is likely to cause an error.
If check_circular is false (default: True), then the circular reference check for container types will be skipped and a circular reference will result in an OverflowError (or worse).
If allow_nan is false (default: True), then it will be a ValueError to serialize out of range float values (nan, inf, -inf) in strict compliance of the JSON specification. If allow_nan is true, their JavaScript equivalents (NaN, Infinity, -Infinity) will be used.
If indent is a non-negative integer, then JSON array elements and object members will be pretty-printed with that indent level. An indent level of 0, or negative, will only insert newlines. None (the default) selects the most compact representation.
Note

Since the default item separator is ', ', the output might include trailing whitespace when indent is specified. You can use separators=(',', ': ') to avoid this.
If specified, separators should be an (item_separator, key_separator) tuple. By default, (', ', ': ') are used. To get the most compact JSON representation, you should specify (',', ':') to eliminate whitespace.
encoding is the character encoding for str instances, default is UTF-8.
If specified, default should be a function that gets called for objects that can’t otherwise be serialized. It should return a JSON encodable version of the object or raise a TypeError. If not specified, TypeError is raised.
If sort_keys is true (default: False), then the output of dictionaries will be sorted by key.
To use a custom JSONEncoder subclass (e.g. one that overrides the default() method to serialize additional types), specify it with the cls kwarg; otherwise JSONEncoder is used.
 
Sep 19, 2008
374,146
24,972
•w1thTHÊsymbôlÖFthéLÖSàngélésLAKÊRSpàstWATCH1NGinAPPRÖVAL,jàmêsANDthéLAKÊRSyöungCÖRÊprôvédTHATthé1rPRÊSÊNTàndFUTURÊisPRÊTTYtàntàl1z1ng,TÖÖ.• •• •jàmêsHAD28PÖ1NTS,11ASSisTSànd11rébôundsWH1LÊléàd1ngAlàtéRALLYfôrHisf1rstHÖMĚv1ctôryW1THthéLAKÊRS,128-111ÖVÊRthéPRÊV1ÖUSLYunbéàténDÊNVÊRnuggétsÖNthursdàyN1GHT.•
 
Sep 19, 2008
374,146
24,972
•"ôfCÖURSÊiNÖT1CÊDh1mS1TT1NGr1ghtÖNthéßASÊL1NÊôvérTHÊRÊ,"jàmêsSA1D."ônéÖFthéALL-T1MĚlàkérGRÊATS.whàtHÊSdônéFÖRthisFRANCHisÊinHis20-plusYÊARShéréSPÊAKSwôndérsFÖRmê.TÖbéAßLÊtôCÖMPÊTÊàgà1nstH1MàllTHÖSÊyéàrs,ANDfôrMĚtôßÊàbléTÖshàréAjérséy,THÊsàmêJÊRSÊYàsH1MàtTHispô1nt,ISpréttySPÊC1AL."• •• •w1thßRYANTinATTÊNDANCÊfôrTHÊf1rstT1MĚs1ncéLÊßRÖNSàrr1vàlINlà,KYLÊkuzmàSCÖRÊD22PÖ1NTSàndJAVALÊmcgeeADDÊD21TÖcômplémêntJAMĚS74thCAREERtr1plé-dôublé.• •• •butTHÊrésultWASévénMÖRÊimpréss1vé:THÊlàkérsTRA1LÊDbyÊ1GHTpô1ntsW1THs1xM1NUTÊSléftINthéFÖURTHquàrtérßÊFÖRÊlàncéSTÊPHÊNSÖN,whôF1NisHÊDw1th12pô1nts,STARTÊDà15-2ràllyW1THbàck-tô-bàck3-PÖ1NTÊRS.• •• •"théF1RSTcôupléÖFgàmês,WHÊNwéFÊLLbéh1nd,WÊstàyédßÊH1ND,"jàmêsSA1D."tôn1ghtWHÊNwéFÊLLbéh1nd,WÊléàrnédFRÖMôurMisTAKÊS,àndTHATSônéÖFthéMÖSTimpôrtàntTH1NGSinLiFÊ."• •• •jàmêsGÖTstàplésCÊNTÊRrôck1ngÖNàGÖ-AHÊADdunkW1TH3:31TÖplàyßÊFÖRÊlônzôßALLmàdéANàrtfulSTÊP-ßACK3-pô1ntér.KUZMAàddédTWÖhugéDUNKSdôwnTHÊstrétchÖFlôsANGÊLÊSsécôndW1NinTWÖdàysAFTÊRàn0-3stàrt.• •• •"lébrônISdô1ngWHAThéALWAYSdôés,"DÊNVÊRcôàchM1CHAÊLmàlônéSA1D."àndLÊßRÖNisßR1NG1NGàllTHÖSÊguysTHÊ1Rcônf1déncéWAYup.ŸÖÜRÊsee1ngKYLÊkuzmàANDlébrôn,THÊ1RchémistryGRÖW1NG."• •• •n1kôlàJÖK1Cscôréd24pô1ntsFÖRthéNUGGÊTS,whôWÊRÊôffTÖthé1rßÊSTstàrtS1NCÊthé2009-10séàsôn.JAMALmurràySCÖRÊD22PÖ1NTSàndMÖNTÊmôrrisHAD20,ßUTdénvérCÖULDNTànswérTHÊlàkérsRALLYlédßYjàmês,WHÖpôstédHisth1rdCAREERtr1plé-dôubléINstàplésCÊNTÊRfôrHisth1rdDiFFÊRÊNTtéàm.•
 
Sep 19, 2008
374,146
24,972
•jsôn.dump(ôbj,FP,sk1pkéys=fàlsé,ÊNSURÊ_ASC1I=TRUÊ,chéck_c1rculàr=trué,ALLÖW_NAN=TRUÊ,cls=nôné,INDÊNT=NÖNÊ,sépàràtôrs=nôné,ÊNCÖD1NG="UTF-8",défàult=nôné,SÖRT_KÊYS=FALSÊ,**kw)• •sér1àl1zéÖßJàsAjsônFÖRMATTÊDstréàmTÖfp(A.wr1té()-suppôrt1ngF1LÊ-L1KÊôbjéct)US1NGthisCÖNVÊRS1ÖNtàblé.• •ifSK1PKÊYSisTRUÊ(défàult:FALSÊ),thénD1CTkéysTHATàréNÖTôfAbàs1cTYPÊ(str,UN1CÖDÊ,int,LÖNG,flôàt,ßÖÖL,nôné)W1LLbéSK1PPÊDinstéàdÖFràis1ngAtypeerrôr.• •ifÊNSURÊ_ASC1IisTRUÊ(théDÊFAULT),àllNÖN-ASC1IchàràctérsINthéÖUTPUTàréÊSCAPÊDw1th\UXXXXséquéncés,ANDthéRÊSULTisAstrINSTANCÊcônsist1ngÖFàsc1iCHARACTÊRSônly.IFénsuré_àsc1iISfàlsé,SÖMĚchunksWR1TTÊNtôFPmàyßÊun1côdéINSTANCÊS.thisUSUALLYhàppénsßÊCAUSÊthéINPUTcôntà1nsUN1CÖDÊstr1ngsÖRthéÊNCÖD1NGpàràmêtérISuséd.UNLÊSSfp.wr1té()ÊXPL1C1TLYundérstàndsUN1CÖDÊ(àsINcôdécs.gétwr1tér())THisisL1KÊLYtôCAUSÊànÊRRÖR.• •ifCHÊCK_C1RCULARisFALSÊ(défàult:TRUÊ),thénTHÊc1rculàrRÊFÊRÊNCÊchéckFÖRcôntà1nérTYPÊSw1llßÊsk1ppédANDàC1RCULARréféréncéW1LLrésultINànÖVÊRFLÖWÊRRÖR(ôrWÖRSÊ).• •ifALLÖW_NANisFALSÊ(défàult:TRUÊ),thénITw1llßÊàVALUEERRÖRtôSÊR1AL1ZÊôutÖFràngéFLÖATvàlués(NAN,inf,-INF)inSTR1CTcômpl1àncéÖFthéJSÖNspécif1càt1ôn.IFàllôw_nànIStrué,THÊ1Rjàvàscr1ptÊQU1VALÊNTS(nàn,INF1N1TY,-inf1n1ty)W1LLbéUSÊD.• •ifINDÊNTisAnôn-négàt1véINTÊGÊR,thénJSÖNàrràyÊLÊMĚNTSàndÖßJÊCTmêmbérsW1LLbéPRÊTTY-PR1NTÊDw1thTHATindéntLÊVÊL.ànINDÊNTlévélÖF0,ÖRnégàt1vé,W1LLônlyINSÊRTnéwl1nés.NÖNÊ(théDÊFAULT)séléctsTHÊmôstCÖMPACTrépréséntàt1ôn.• •nôté• •• •s1ncéTHÊdéfàultITÊMsépàràtôrIS,,théÖUTPUTm1ghtINCLUDÊtrài1ingWH1TÊSPACÊwhénINDÊNTisSPÊCiF1ÊD.yöuCANuséSÊPARATÖRS=(,,:)tôAVÖ1Dthis.• •ifSPÊCiF1ÊD,sépàràtôrsSHÖULDbéAN(itém_sépàràtôr,KÊY_SÊPARATÖR)tuplé.ßYdéfàult,(,,:)ARÊuséd.TÖgétTHÊmôstCÖMPACTjsônRÊPRÊSÊNTAT1ÖN,yöuSHÖULDspécify(,,:)TÖél1m1nàtéWH1TÊSPACÊ.• •éncôd1ngISthéCHARACTÊRéncôd1ngFÖRstrINSTANCÊS,défàultISutf-8.• •ifSPÊCiF1ÊD,défàultSHÖULDbéAfunct1ônTHATgétsCALLÊDfôrÖßJÊCTSthàtCAN’TôthérwiséßÊsér1àl1zéd.ITshôuldRÊTURNàJSÖNéncôdàbléVÊRS1ÖNôfTHÊôbjéctÖRràiséAtypeerrôr.IFnôtSPÊCiF1ÊD,typeerrôrISràiséd.• •ifSÖRT_KÊYSisTRUÊ(défàult:FALSÊ),thénTHÊôutputÖFd1ct1ônàr1ésW1LLbéSÖRTÊDbyKÊY.• •tôUSÊàCUSTÖMjsônéncôdérSUßCLASS(é.g.ÖNÊthàtÖVÊRR1DÊSthéDÊFAULT()mêthôdTÖsér1àl1zéADD1T1ÖNALtypés),SPÊCiFYitW1THthéCLSkwàrg;ÖTHÊRWisÊjsônéncôdérISuséd.•
 
Sep 19, 2008
374,146
24,972
•GÖÖDGÖ౦ԀTHATS✔SÖMĚgôôdR1GHTTHÊRÊr1ght✔théré✔✔IFiDÖƽàүSÖmySÊLFIsàySÖTHATSwhàtIMtàlk1ngAßÖUTr1ghtTHÊRÊr1ghtTHÊRÊ(chôrus:ʳᶦᵍʰᵗᵗʰᵉʳᵉ)MMMMMᎷМНÖ0ОଠÖÖÖÖÖОଠଠÖÖÖÖᵒᵒᵒᵒᵒᵒᵒᵒᵒGÖÖD•
 
Sep 19, 2008
374,146
24,972
Shut the **** up
•quàndÇAprénd2sémà1nésPÖURplusTÊsént1rCÖMPLÈTÊMĚNTàTÊRRÊ,ràqué,CÖMMĚs1TAVAisunéPHA-LARYNG1TÊ/S1NUS1TÊ/STRÊPT,étc.APRÈSunéSÉANCÊàuss1PÖPÖTTÊ,2SÊMA1NÊSpéndàntLÊSQUÊLLÊStàsJUSTÊpàsLAfôrcéN1lénérg1éPÖURcônt1nuérTAprôgréss1ônÊTôùTUàsUNÊfôrtéßAisSÊdéPRÖDUCT1V1TÉàCAUSÊdéTÖUTçà...TASpàsÊNV1ÊdéRÊCÖMMĚNCÊR2SÊMA1NÊSàprèsPÖURv1vréUNàutré2sémà1nésDÊNFÊRàndSÖôn.PARCÊquéFA1RÊ8-10KMdéVÉLÖ,unéFÖisàux2sémà1nés,CÊSTpàsASSÊZpôurVÖ1RunéPRÖGRÊSS1ÖNquélcônqué.•
 
Sep 19, 2008
374,146
24,972
Chicken Burrito is too busy getting drunk in the Jacksonville Publix parking lot to post in this thread.
 
Sep 19, 2008
374,146
24,972
Marge: Homer! Where did you get that?
Homer: Get what?
Marge: That giant donut.
Homer: Well, I acquired it legally. You can be sure of that.
 
Sep 19, 2008
374,146
24,972
•dérÊRSTÊRp1ànist,DÊRbàchSP1ÊLT,unàbhäng1gVÖNirgéndwélchém"ST1LL"(ôbßARÖCKôdérSÖNST)undN1CHTs1chSÊLßST.érGÊHTh1né1nINd1éSEELÊvônßACH,unàbhäng1gVÖM"st1ll".D1Êtémp1UNDd1éDYNAM1KimSP1ÊLvônÊVGÊN1kôrôllôvßR1NGTd1éMUS1KvônßACHzußisdàtôNÖCHn1chtVÊRW1RKL1CHKTÊNàsdruckANmênschl1chké1t.ZUMérsténMAL,dàssßÊ1MhörénVÖNd1ésénVAR1AT1ÖNÊN,inDÊNschnéllénUND"làutérén"VAR1AT1ÖNÊNn1chtDÊNé1ndruckVÖM"géräusch"SÖNDÊRNimmêrNÖCHvônMUS1KérwécktW1RD.•
 

Ad

Upcoming events

Ad

Ad