<rt id="bn8ez"></rt>
<label id="bn8ez"></label>

  • <span id="bn8ez"></span>

    <label id="bn8ez"><meter id="bn8ez"></meter></label>

    weidagang2046的專欄

    物格而后知致
    隨筆 - 8, 文章 - 409, 評論 - 101, 引用 - 0
    數據加載中……

    怎樣把一個二維數組寫入文件

    發信人: ilovecpp (cpp), 信區: Python
    標  題: Re: 怎樣把一個二維數組寫入文件?
    發信站: 水木社區 (Tue Jan 17 23:39:50 2006), 站內

    【 在 petre (petre) 的大作中提到: 】
    : 比如
    : A=[[1,2,3,4],[5,6,7,8],[9,10,11,12],[13,14,15,16]]
    : 寫入文件后文件內容是
    : 1 2 3 4
    : 5 6 7 8
    : 9 10 11 12
    : 13 14 15 16
    : 就是不能帶"[ ]"
    : 每行占一行
    : 急著用,不熟悉python
    : //bow

    print >>open('a.txt', 'w'), '\n'.join([' '.join(map(str, i)) for i in A])

    posted on 2006-01-19 15:48 weidagang2046 閱讀(4872) 評論(1)  編輯  收藏 所屬分類: Python

    評論

    # re: 怎樣把一個二維數組寫入文件  回復  更多評論   

    map(...)
    map(function, sequence[, sequence, ...]) -> list

    Return a list of the results of applying the function to the items of
    the argument sequence(s). If more than one sequence is given, the
    function is called with an argument list consisting of the corresponding
    item of each sequence, substituting None for missing values when not all
    sequences have the same length. If the function is None, return a list of
    the items of the sequence (or a list of tuples if more than one sequence).
    2006-01-19 15:49 | weidagang2046

    只有注冊用戶登錄后才能發表評論。


    網站導航:
     
    主站蜘蛛池模板: 久九九精品免费视频| 亚洲VA成无码人在线观看天堂| 老司机午夜免费视频| 亚洲中文字幕无码不卡电影 | 在线观看黄片免费入口不卡| 亚洲成人免费在线| 免费观看男人免费桶女人视频| 一级毛片免费视频网站| 亚洲精品国产成人| 成人亚洲综合天堂| 1000部拍拍拍18勿入免费凤凰福利 | 成年大片免费高清在线看黄| 亚洲精品免费视频| 免费国产成人午夜私人影视| 无码精品一区二区三区免费视频| 亚洲欧美日韩综合久久久| 国产AV无码专区亚洲AV毛网站| 国产精品美女午夜爽爽爽免费| 美女被免费网站91色| 亚洲自偷自偷在线成人网站传媒| 亚洲精品蜜桃久久久久久| 午夜视频免费成人| 亚洲视频在线观看免费| 色一情一乱一伦一视频免费看| 亚洲精品在线电影| 国产亚洲情侣一区二区无码AV| 毛片免费全部免费观看| 久久成人a毛片免费观看网站| 美女视频黄a视频全免费网站一区| 亚洲狠狠ady亚洲精品大秀| 一本色道久久综合亚洲精品高清| 无码国产精品一区二区免费I6| 久久免费视频观看| 国产黄在线观看免费观看不卡| 亚洲人成人伊人成综合网无码| 老司机亚洲精品影院无码| 亚洲熟妇中文字幕五十中出| 亚洲AV网站在线观看| 国产高清视频在线免费观看| 免费看美女裸露无档网站| 久久久久久国产精品免费无码|