By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
444,199 Members | 1,209 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 444,199 IT Pros & Developers. It's quick & easy.

how do i split a joining multiple file

P: 1
i've a problem to split a join multiple file.
here's my code to join a multiple file.
Expand|Select|Wrap|Line Numbers
  1. import sys
  2. import os
  4. f = open("e:/Dev/1.jpg", "rb")
  5. g = open("e:/Dev/2.mp3", "rb")
  6. dataList = []
  7. dataList.append(
  8. dataList.append(
  9. g.close()
  11. data =
  12. new =
  13. f = open(new, 'wb')
  14. for data in dataList:
  15.     f.write(data)
  16. f.close()
  17. os.remove(
my goal is to hide 2nd file in 1st file. a 1st file can be accessed although it contains 2nd file in it.

but now a problem is to split this kind of file, so it'll back to original form.
note that a join and split code must be separated.
any idea would be help.
Apr 26 '11 #1
Share this question for a faster answer!
Share on Google+

Post your reply

Sign in to post your reply or Sign up for a free account.