Advertisement
Guest User

Untitled

a guest
Apr 22nd, 2019
106
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 32.75 KB | None | 0 0
  1. {
  2. "cells": [
  3. {
  4. "cell_type": "code",
  5. "execution_count": 2,
  6. "metadata": {},
  7. "outputs": [
  8. {
  9. "name": "stdout",
  10. "output_type": "stream",
  11. "text": [
  12. "hello python\n"
  13. ]
  14. }
  15. ],
  16. "source": [
  17. "print (\"hello python\")"
  18. ]
  19. },
  20. {
  21. "cell_type": "code",
  22. "execution_count": 3,
  23. "metadata": {},
  24. "outputs": [
  25. {
  26. "name": "stdout",
  27. "output_type": "stream",
  28. "text": [
  29. "3.6.8 |Anaconda, Inc.| (default, Dec 30 2018, 01:22:34) \n",
  30. "[GCC 7.3.0]\n"
  31. ]
  32. }
  33. ],
  34. "source": [
  35. "import sys\n",
  36. "print (sys.version)"
  37. ]
  38. },
  39. {
  40. "cell_type": "code",
  41. "execution_count": 8,
  42. "metadata": {},
  43. "outputs": [
  44. {
  45. "name": "stdout",
  46. "output_type": "stream",
  47. "text": [
  48. "hello python\n"
  49. ]
  50. }
  51. ],
  52. "source": [
  53. "x= \"hello python\"\n",
  54. "print(x) # this is string command"
  55. ]
  56. },
  57. {
  58. "cell_type": "code",
  59. "execution_count": 10,
  60. "metadata": {},
  61. "outputs": [
  62. {
  63. "name": "stdout",
  64. "output_type": "stream",
  65. "text": [
  66. "This will be printed\n"
  67. ]
  68. },
  69. {
  70. "ename": "NameError",
  71. "evalue": "name 'frint' is not defined",
  72. "output_type": "error",
  73. "traceback": [
  74. "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
  75. "\u001b[0;31mNameError\u001b[0m Traceback (most recent call last)",
  76. "\u001b[0;32m<ipython-input-10-af59af1b345d>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[1;32m 2\u001b[0m \u001b[0;34m\u001b[0m\u001b[0m\n\u001b[1;32m 3\u001b[0m \u001b[0mprint\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\"This will be printed\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0;32m----> 4\u001b[0;31m \u001b[0mfrint\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\"This will cause an error\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m\u001b[1;32m 5\u001b[0m \u001b[0mprint\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\"This will NOT be printed\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n",
  77. "\u001b[0;31mNameError\u001b[0m: name 'frint' is not defined"
  78. ]
  79. }
  80. ],
  81. "source": [
  82. "# Print string and error to see the running order\n",
  83. "\n",
  84. "print(\"This will be printed\")\n",
  85. "frint(\"This will cause an error\")\n",
  86. "print(\"This will NOT be printed\")"
  87. ]
  88. },
  89. {
  90. "cell_type": "code",
  91. "execution_count": 11,
  92. "metadata": {},
  93. "outputs": [
  94. {
  95. "name": "stdout",
  96. "output_type": "stream",
  97. "text": [
  98. "Hello, world!\n"
  99. ]
  100. }
  101. ],
  102. "source": [
  103. "print(\"Hello, world!\") # Print the traditional hello world"
  104. ]
  105. },
  106. {
  107. "cell_type": "code",
  108. "execution_count": 13,
  109. "metadata": {},
  110. "outputs": [],
  111. "source": [
  112. "name =\"Michael Jackson\""
  113. ]
  114. },
  115. {
  116. "cell_type": "code",
  117. "execution_count": 15,
  118. "metadata": {},
  119. "outputs": [
  120. {
  121. "name": "stdout",
  122. "output_type": "stream",
  123. "text": [
  124. "M\n"
  125. ]
  126. }
  127. ],
  128. "source": [
  129. "print(name[0])"
  130. ]
  131. },
  132. {
  133. "cell_type": "code",
  134. "execution_count": 18,
  135. "metadata": {},
  136. "outputs": [
  137. {
  138. "name": "stdout",
  139. "output_type": "stream",
  140. "text": [
  141. "J\n"
  142. ]
  143. }
  144. ],
  145. "source": [
  146. "print(name[8])"
  147. ]
  148. },
  149. {
  150. "cell_type": "code",
  151. "execution_count": 19,
  152. "metadata": {},
  153. "outputs": [
  154. {
  155. "name": "stdout",
  156. "output_type": "stream",
  157. "text": [
  158. "n\n"
  159. ]
  160. }
  161. ],
  162. "source": [
  163. "print(name[-1])"
  164. ]
  165. },
  166. {
  167. "cell_type": "code",
  168. "execution_count": 20,
  169. "metadata": {},
  170. "outputs": [
  171. {
  172. "name": "stdout",
  173. "output_type": "stream",
  174. "text": [
  175. "i\n"
  176. ]
  177. }
  178. ],
  179. "source": [
  180. "print(name[-14])"
  181. ]
  182. },
  183. {
  184. "cell_type": "code",
  185. "execution_count": 21,
  186. "metadata": {},
  187. "outputs": [
  188. {
  189. "data": {
  190. "text/plain": [
  191. "15"
  192. ]
  193. },
  194. "execution_count": 21,
  195. "metadata": {},
  196. "output_type": "execute_result"
  197. }
  198. ],
  199. "source": [
  200. "len(name)"
  201. ]
  202. },
  203. {
  204. "cell_type": "code",
  205. "execution_count": 23,
  206. "metadata": {},
  207. "outputs": [
  208. {
  209. "name": "stdout",
  210. "output_type": "stream",
  211. "text": [
  212. "Michael\n"
  213. ]
  214. }
  215. ],
  216. "source": [
  217. "print(name[0:7])"
  218. ]
  219. },
  220. {
  221. "cell_type": "code",
  222. "execution_count": 24,
  223. "metadata": {},
  224. "outputs": [
  225. {
  226. "name": "stdout",
  227. "output_type": "stream",
  228. "text": [
  229. " Jackson\n"
  230. ]
  231. }
  232. ],
  233. "source": [
  234. "print(name[7:15])"
  235. ]
  236. },
  237. {
  238. "cell_type": "code",
  239. "execution_count": 25,
  240. "metadata": {},
  241. "outputs": [
  242. {
  243. "name": "stdout",
  244. "output_type": "stream",
  245. "text": [
  246. "McalJcsn\n"
  247. ]
  248. }
  249. ],
  250. "source": [
  251. "print(name[::2])"
  252. ]
  253. },
  254. {
  255. "cell_type": "code",
  256. "execution_count": 26,
  257. "metadata": {},
  258. "outputs": [
  259. {
  260. "name": "stdout",
  261. "output_type": "stream",
  262. "text": [
  263. "Mhlas\n"
  264. ]
  265. }
  266. ],
  267. "source": [
  268. "print(name[::3])"
  269. ]
  270. },
  271. {
  272. "cell_type": "code",
  273. "execution_count": 31,
  274. "metadata": {},
  275. "outputs": [],
  276. "source": [
  277. "statement = name + \" is the best\""
  278. ]
  279. },
  280. {
  281. "cell_type": "code",
  282. "execution_count": 32,
  283. "metadata": {},
  284. "outputs": [
  285. {
  286. "name": "stdout",
  287. "output_type": "stream",
  288. "text": [
  289. "Michael Jackson is the best\n"
  290. ]
  291. }
  292. ],
  293. "source": [
  294. "print(statement)"
  295. ]
  296. },
  297. {
  298. "cell_type": "code",
  299. "execution_count": 47,
  300. "metadata": {},
  301. "outputs": [
  302. {
  303. "name": "stdout",
  304. "output_type": "stream",
  305. "text": [
  306. "name \n",
  307. "statement\n"
  308. ]
  309. }
  310. ],
  311. "source": [
  312. "print (\"name \\nstatement\")"
  313. ]
  314. },
  315. {
  316. "cell_type": "code",
  317. "execution_count": 48,
  318. "metadata": {},
  319. "outputs": [
  320. {
  321. "name": "stdout",
  322. "output_type": "stream",
  323. "text": [
  324. "before upper: Thriller is the sixth studio album\n",
  325. "After upper: THRILLER IS THE SIXTH STUDIO ALBUM\n"
  326. ]
  327. }
  328. ],
  329. "source": [
  330. "A = \"Thriller is the sixth studio album\"\n",
  331. "print(\"before upper:\", A)\n",
  332. "B = A.upper()\n",
  333. "print(\"After upper:\", B)"
  334. ]
  335. },
  336. {
  337. "cell_type": "code",
  338. "execution_count": 49,
  339. "metadata": {},
  340. "outputs": [],
  341. "source": [
  342. "c= A.upper()"
  343. ]
  344. },
  345. {
  346. "cell_type": "code",
  347. "execution_count": 50,
  348. "metadata": {},
  349. "outputs": [
  350. {
  351. "name": "stdout",
  352. "output_type": "stream",
  353. "text": [
  354. "THRILLER IS THE SIXTH STUDIO ALBUM\n"
  355. ]
  356. }
  357. ],
  358. "source": [
  359. "print(c)"
  360. ]
  361. },
  362. {
  363. "cell_type": "code",
  364. "execution_count": 53,
  365. "metadata": {},
  366. "outputs": [
  367. {
  368. "name": "stdout",
  369. "output_type": "stream",
  370. "text": [
  371. "show is the sixth studio album\n"
  372. ]
  373. }
  374. ],
  375. "source": [
  376. "d=A.replace(\"Thriller\", \"show\")\n",
  377. "print(d)"
  378. ]
  379. },
  380. {
  381. "cell_type": "code",
  382. "execution_count": 54,
  383. "metadata": {},
  384. "outputs": [
  385. {
  386. "data": {
  387. "text/plain": [
  388. "5"
  389. ]
  390. },
  391. "execution_count": 54,
  392. "metadata": {},
  393. "output_type": "execute_result"
  394. }
  395. ],
  396. "source": [
  397. "Name = \"Michael Jackson\"\n",
  398. "Name.find('el')"
  399. ]
  400. },
  401. {
  402. "cell_type": "code",
  403. "execution_count": 55,
  404. "metadata": {},
  405. "outputs": [
  406. {
  407. "data": {
  408. "text/plain": [
  409. "18"
  410. ]
  411. },
  412. "execution_count": 55,
  413. "metadata": {},
  414. "output_type": "execute_result"
  415. }
  416. ],
  417. "source": [
  418. "d.find(\"stu\")"
  419. ]
  420. },
  421. {
  422. "cell_type": "code",
  423. "execution_count": 56,
  424. "metadata": {},
  425. "outputs": [
  426. {
  427. "data": {
  428. "text/plain": [
  429. "-1"
  430. ]
  431. },
  432. "execution_count": 56,
  433. "metadata": {},
  434. "output_type": "execute_result"
  435. }
  436. ],
  437. "source": [
  438. "Name.find('Jasdfasdasdf')"
  439. ]
  440. },
  441. {
  442. "cell_type": "code",
  443. "execution_count": 59,
  444. "metadata": {},
  445. "outputs": [],
  446. "source": [
  447. "a = \"1\"\n"
  448. ]
  449. },
  450. {
  451. "cell_type": "code",
  452. "execution_count": 58,
  453. "metadata": {},
  454. "outputs": [],
  455. "source": [
  456. "b= \"2\"\n"
  457. ]
  458. },
  459. {
  460. "cell_type": "code",
  461. "execution_count": 61,
  462. "metadata": {},
  463. "outputs": [
  464. {
  465. "name": "stdout",
  466. "output_type": "stream",
  467. "text": [
  468. "12\n"
  469. ]
  470. }
  471. ],
  472. "source": [
  473. "c= a+b\n",
  474. "print(c)"
  475. ]
  476. },
  477. {
  478. "cell_type": "code",
  479. "execution_count": 62,
  480. "metadata": {},
  481. "outputs": [],
  482. "source": [
  483. "d=\"abcdefgh\""
  484. ]
  485. },
  486. {
  487. "cell_type": "code",
  488. "execution_count": 63,
  489. "metadata": {},
  490. "outputs": [
  491. {
  492. "name": "stdout",
  493. "output_type": "stream",
  494. "text": [
  495. "abc\n"
  496. ]
  497. }
  498. ],
  499. "source": [
  500. "print(d[0:3])"
  501. ]
  502. },
  503. {
  504. "cell_type": "code",
  505. "execution_count": 64,
  506. "metadata": {},
  507. "outputs": [
  508. {
  509. "name": "stdout",
  510. "output_type": "stream",
  511. "text": [
  512. "aceg\n"
  513. ]
  514. }
  515. ],
  516. "source": [
  517. "print(d[::2])"
  518. ]
  519. },
  520. {
  521. "cell_type": "code",
  522. "execution_count": 65,
  523. "metadata": {},
  524. "outputs": [
  525. {
  526. "name": "stdout",
  527. "output_type": "stream",
  528. "text": [
  529. "\\\n"
  530. ]
  531. }
  532. ],
  533. "source": [
  534. "print(\"\\\\\")"
  535. ]
  536. },
  537. {
  538. "cell_type": "code",
  539. "execution_count": 67,
  540. "metadata": {},
  541. "outputs": [
  542. {
  543. "name": "stdout",
  544. "output_type": "stream",
  545. "text": [
  546. "YOU ARE WRONG\n"
  547. ]
  548. }
  549. ],
  550. "source": [
  551. "F = \"You are wrong\"\n",
  552. "T = F.upper()\n",
  553. "print(T)"
  554. ]
  555. },
  556. {
  557. "cell_type": "code",
  558. "execution_count": 68,
  559. "metadata": {},
  560. "outputs": [
  561. {
  562. "data": {
  563. "text/plain": [
  564. "'2'"
  565. ]
  566. },
  567. "execution_count": 68,
  568. "metadata": {},
  569. "output_type": "execute_result"
  570. }
  571. ],
  572. "source": [
  573. "str(1+1)"
  574. ]
  575. },
  576. {
  577. "cell_type": "code",
  578. "execution_count": 70,
  579. "metadata": {},
  580. "outputs": [],
  581. "source": [
  582. "var = '01234567'"
  583. ]
  584. },
  585. {
  586. "cell_type": "code",
  587. "execution_count": 74,
  588. "metadata": {},
  589. "outputs": [
  590. {
  591. "name": "stdout",
  592. "output_type": "stream",
  593. "text": [
  594. "0246\n"
  595. ]
  596. }
  597. ],
  598. "source": [
  599. "print(var[::2])"
  600. ]
  601. },
  602. {
  603. "cell_type": "code",
  604. "execution_count": 75,
  605. "metadata": {},
  606. "outputs": [],
  607. "source": [
  608. "tuple1=(\"disco\",10,1.2)"
  609. ]
  610. },
  611. {
  612. "cell_type": "code",
  613. "execution_count": 76,
  614. "metadata": {},
  615. "outputs": [
  616. {
  617. "data": {
  618. "text/plain": [
  619. "('disco', 10, 1.2)"
  620. ]
  621. },
  622. "execution_count": 76,
  623. "metadata": {},
  624. "output_type": "execute_result"
  625. }
  626. ],
  627. "source": [
  628. "tuple1"
  629. ]
  630. },
  631. {
  632. "cell_type": "code",
  633. "execution_count": 77,
  634. "metadata": {},
  635. "outputs": [
  636. {
  637. "data": {
  638. "text/plain": [
  639. "tuple"
  640. ]
  641. },
  642. "execution_count": 77,
  643. "metadata": {},
  644. "output_type": "execute_result"
  645. }
  646. ],
  647. "source": [
  648. "type(tuple1)"
  649. ]
  650. },
  651. {
  652. "cell_type": "code",
  653. "execution_count": 79,
  654. "metadata": {},
  655. "outputs": [
  656. {
  657. "name": "stdout",
  658. "output_type": "stream",
  659. "text": [
  660. "disco\n",
  661. "10\n",
  662. "1.2\n"
  663. ]
  664. }
  665. ],
  666. "source": [
  667. "print(tuple1[0])\n",
  668. "print(tuple1[1])\n",
  669. "print(tuple1[2])"
  670. ]
  671. },
  672. {
  673. "cell_type": "code",
  674. "execution_count": 80,
  675. "metadata": {},
  676. "outputs": [
  677. {
  678. "name": "stdout",
  679. "output_type": "stream",
  680. "text": [
  681. "1.2\n",
  682. "10\n",
  683. "disco\n"
  684. ]
  685. }
  686. ],
  687. "source": [
  688. "print(tuple1[-1])\n",
  689. "print(tuple1[-2])\n",
  690. "print(tuple1[-3])"
  691. ]
  692. },
  693. {
  694. "cell_type": "code",
  695. "execution_count": 83,
  696. "metadata": {},
  697. "outputs": [],
  698. "source": [
  699. "tuple2= tuple1 +(\"hardrock\",10)"
  700. ]
  701. },
  702. {
  703. "cell_type": "code",
  704. "execution_count": 85,
  705. "metadata": {},
  706. "outputs": [
  707. {
  708. "data": {
  709. "text/plain": [
  710. "('disco', 10, 1.2, 'hardrock')"
  711. ]
  712. },
  713. "execution_count": 85,
  714. "metadata": {},
  715. "output_type": "execute_result"
  716. }
  717. ],
  718. "source": [
  719. "tuple2[0:4]"
  720. ]
  721. },
  722. {
  723. "cell_type": "code",
  724. "execution_count": 86,
  725. "metadata": {},
  726. "outputs": [
  727. {
  728. "data": {
  729. "text/plain": [
  730. "('hardrock', 10)"
  731. ]
  732. },
  733. "execution_count": 86,
  734. "metadata": {},
  735. "output_type": "execute_result"
  736. }
  737. ],
  738. "source": [
  739. "tuple2[3:5]"
  740. ]
  741. },
  742. {
  743. "cell_type": "code",
  744. "execution_count": 87,
  745. "metadata": {},
  746. "outputs": [
  747. {
  748. "data": {
  749. "text/plain": [
  750. "5"
  751. ]
  752. },
  753. "execution_count": 87,
  754. "metadata": {},
  755. "output_type": "execute_result"
  756. }
  757. ],
  758. "source": [
  759. "len(tuple2)"
  760. ]
  761. },
  762. {
  763. "cell_type": "code",
  764. "execution_count": 88,
  765. "metadata": {},
  766. "outputs": [],
  767. "source": [
  768. "Ratings = (0, 9, 6, 5, 10, 8, 9, 6, 2)"
  769. ]
  770. },
  771. {
  772. "cell_type": "code",
  773. "execution_count": 90,
  774. "metadata": {},
  775. "outputs": [
  776. {
  777. "data": {
  778. "text/plain": [
  779. "[0, 2, 5, 6, 6, 8, 9, 9, 10]"
  780. ]
  781. },
  782. "execution_count": 90,
  783. "metadata": {},
  784. "output_type": "execute_result"
  785. }
  786. ],
  787. "source": [
  788. "sortedratings= sorted(Ratings)\n",
  789. "sortedratings"
  790. ]
  791. },
  792. {
  793. "cell_type": "code",
  794. "execution_count": 91,
  795. "metadata": {},
  796. "outputs": [],
  797. "source": [
  798. "\n",
  799. "NestedT =(1, 2, (\"pop\", \"rock\") ,(3,4),(\"disco\",(1,2)))"
  800. ]
  801. },
  802. {
  803. "cell_type": "code",
  804. "execution_count": 93,
  805. "metadata": {},
  806. "outputs": [
  807. {
  808. "data": {
  809. "text/plain": [
  810. "(1, 2, ('pop', 'rock'), (3, 4), ('disco', (1, 2)))"
  811. ]
  812. },
  813. "execution_count": 93,
  814. "metadata": {},
  815. "output_type": "execute_result"
  816. }
  817. ],
  818. "source": [
  819. "NestedT"
  820. ]
  821. },
  822. {
  823. "cell_type": "code",
  824. "execution_count": 94,
  825. "metadata": {},
  826. "outputs": [
  827. {
  828. "data": {
  829. "text/plain": [
  830. "5"
  831. ]
  832. },
  833. "execution_count": 94,
  834. "metadata": {},
  835. "output_type": "execute_result"
  836. }
  837. ],
  838. "source": [
  839. "len(NestedT)"
  840. ]
  841. },
  842. {
  843. "cell_type": "code",
  844. "execution_count": 95,
  845. "metadata": {},
  846. "outputs": [
  847. {
  848. "name": "stdout",
  849. "output_type": "stream",
  850. "text": [
  851. "Element 0 of Tuple: 1\n",
  852. "Element 1 of Tuple: 2\n",
  853. "Element 2 of Tuple: ('pop', 'rock')\n",
  854. "Element 3 of Tuple: (3, 4)\n",
  855. "Element 4 of Tuple: ('disco', (1, 2))\n"
  856. ]
  857. }
  858. ],
  859. "source": [
  860. "print(\"Element 0 of Tuple: \", NestedT[0])\n",
  861. "print(\"Element 1 of Tuple: \", NestedT[1])\n",
  862. "print(\"Element 2 of Tuple: \", NestedT[2])\n",
  863. "print(\"Element 3 of Tuple: \", NestedT[3])\n",
  864. "print(\"Element 4 of Tuple: \", NestedT[4])"
  865. ]
  866. },
  867. {
  868. "cell_type": "code",
  869. "execution_count": 96,
  870. "metadata": {},
  871. "outputs": [
  872. {
  873. "data": {
  874. "text/plain": [
  875. "'r'"
  876. ]
  877. },
  878. "execution_count": 96,
  879. "metadata": {},
  880. "output_type": "execute_result"
  881. }
  882. ],
  883. "source": [
  884. "NestedT[2][1][0]"
  885. ]
  886. },
  887. {
  888. "cell_type": "code",
  889. "execution_count": 98,
  890. "metadata": {},
  891. "outputs": [
  892. {
  893. "data": {
  894. "text/plain": [
  895. "1"
  896. ]
  897. },
  898. "execution_count": 98,
  899. "metadata": {},
  900. "output_type": "execute_result"
  901. }
  902. ],
  903. "source": [
  904. "NestedT[4][1][0]"
  905. ]
  906. },
  907. {
  908. "cell_type": "code",
  909. "execution_count": 99,
  910. "metadata": {},
  911. "outputs": [
  912. {
  913. "data": {
  914. "text/plain": [
  915. "('pop',\n",
  916. " 'rock',\n",
  917. " 'soul',\n",
  918. " 'hard rock',\n",
  919. " 'soft rock',\n",
  920. " 'R&B',\n",
  921. " 'progressive rock',\n",
  922. " 'disco')"
  923. ]
  924. },
  925. "execution_count": 99,
  926. "metadata": {},
  927. "output_type": "execute_result"
  928. }
  929. ],
  930. "source": [
  931. "genres_tuple = (\"pop\", \"rock\", \"soul\", \"hard rock\", \"soft rock\", \\\n",
  932. " \"R&B\", \"progressive rock\", \"disco\") \n",
  933. "genres_tuple"
  934. ]
  935. },
  936. {
  937. "cell_type": "code",
  938. "execution_count": 100,
  939. "metadata": {},
  940. "outputs": [
  941. {
  942. "data": {
  943. "text/plain": [
  944. "8"
  945. ]
  946. },
  947. "execution_count": 100,
  948. "metadata": {},
  949. "output_type": "execute_result"
  950. }
  951. ],
  952. "source": [
  953. "len(genres_tuple)"
  954. ]
  955. },
  956. {
  957. "cell_type": "code",
  958. "execution_count": 101,
  959. "metadata": {},
  960. "outputs": [
  961. {
  962. "data": {
  963. "text/plain": [
  964. "'hard rock'"
  965. ]
  966. },
  967. "execution_count": 101,
  968. "metadata": {},
  969. "output_type": "execute_result"
  970. }
  971. ],
  972. "source": [
  973. "genres_tuple[3]"
  974. ]
  975. },
  976. {
  977. "cell_type": "code",
  978. "execution_count": 102,
  979. "metadata": {},
  980. "outputs": [
  981. {
  982. "data": {
  983. "text/plain": [
  984. "('hard rock', 'soft rock', 'R&B')"
  985. ]
  986. },
  987. "execution_count": 102,
  988. "metadata": {},
  989. "output_type": "execute_result"
  990. }
  991. ],
  992. "source": [
  993. "genres_tuple[3:6]"
  994. ]
  995. },
  996. {
  997. "cell_type": "code",
  998. "execution_count": 103,
  999. "metadata": {},
  1000. "outputs": [
  1001. {
  1002. "data": {
  1003. "text/plain": [
  1004. "('pop', 'rock')"
  1005. ]
  1006. },
  1007. "execution_count": 103,
  1008. "metadata": {},
  1009. "output_type": "execute_result"
  1010. }
  1011. ],
  1012. "source": [
  1013. "genres_tuple[0:2]"
  1014. ]
  1015. },
  1016. {
  1017. "cell_type": "code",
  1018. "execution_count": 107,
  1019. "metadata": {},
  1020. "outputs": [
  1021. {
  1022. "data": {
  1023. "text/plain": [
  1024. "'d'"
  1025. ]
  1026. },
  1027. "execution_count": 107,
  1028. "metadata": {},
  1029. "output_type": "execute_result"
  1030. }
  1031. ],
  1032. "source": [
  1033. "genres_tuple[7][0]"
  1034. ]
  1035. },
  1036. {
  1037. "cell_type": "code",
  1038. "execution_count": 108,
  1039. "metadata": {},
  1040. "outputs": [
  1041. {
  1042. "data": {
  1043. "text/plain": [
  1044. "7"
  1045. ]
  1046. },
  1047. "execution_count": 108,
  1048. "metadata": {},
  1049. "output_type": "execute_result"
  1050. }
  1051. ],
  1052. "source": [
  1053. "genres_tuple.index(\"disco\")"
  1054. ]
  1055. },
  1056. {
  1057. "cell_type": "code",
  1058. "execution_count": 109,
  1059. "metadata": {},
  1060. "outputs": [],
  1061. "source": [
  1062. "C_tuple=(-5, 1, -3)"
  1063. ]
  1064. },
  1065. {
  1066. "cell_type": "code",
  1067. "execution_count": 110,
  1068. "metadata": {},
  1069. "outputs": [],
  1070. "source": [
  1071. "sortedtuple=sorted(C_tuple)"
  1072. ]
  1073. },
  1074. {
  1075. "cell_type": "code",
  1076. "execution_count": 111,
  1077. "metadata": {},
  1078. "outputs": [
  1079. {
  1080. "data": {
  1081. "text/plain": [
  1082. "[-5, -3, 1]"
  1083. ]
  1084. },
  1085. "execution_count": 111,
  1086. "metadata": {},
  1087. "output_type": "execute_result"
  1088. }
  1089. ],
  1090. "source": [
  1091. "sortedtuple"
  1092. ]
  1093. },
  1094. {
  1095. "cell_type": "code",
  1096. "execution_count": 112,
  1097. "metadata": {},
  1098. "outputs": [
  1099. {
  1100. "data": {
  1101. "text/plain": [
  1102. "['Michael Jackson', 10.2, 'pop', 10]"
  1103. ]
  1104. },
  1105. "execution_count": 112,
  1106. "metadata": {},
  1107. "output_type": "execute_result"
  1108. }
  1109. ],
  1110. "source": [
  1111. "L = [ \"Michael Jackson\", 10.2]\n",
  1112. "L.extend(['pop', 10])\n",
  1113. "L"
  1114. ]
  1115. },
  1116. {
  1117. "cell_type": "code",
  1118. "execution_count": 113,
  1119. "metadata": {},
  1120. "outputs": [
  1121. {
  1122. "data": {
  1123. "text/plain": [
  1124. "['Michael Jackson', 10.2, ['pop', 10]]"
  1125. ]
  1126. },
  1127. "execution_count": 113,
  1128. "metadata": {},
  1129. "output_type": "execute_result"
  1130. }
  1131. ],
  1132. "source": [
  1133. "L = [ \"Michael Jackson\", 10.2]\n",
  1134. "L.append(['pop', 10])\n",
  1135. "L"
  1136. ]
  1137. },
  1138. {
  1139. "cell_type": "code",
  1140. "execution_count": 114,
  1141. "metadata": {},
  1142. "outputs": [
  1143. {
  1144. "name": "stdout",
  1145. "output_type": "stream",
  1146. "text": [
  1147. "Before change: ['disco', 10, 1.2]\n",
  1148. "After change: ['hard rock', 10, 1.2]\n"
  1149. ]
  1150. }
  1151. ],
  1152. "source": [
  1153. "A = [\"disco\", 10, 1.2]\n",
  1154. "print('Before change:', A)\n",
  1155. "A[0] = 'hard rock'\n",
  1156. "print('After change:', A)"
  1157. ]
  1158. },
  1159. {
  1160. "cell_type": "code",
  1161. "execution_count": 115,
  1162. "metadata": {},
  1163. "outputs": [
  1164. {
  1165. "name": "stdout",
  1166. "output_type": "stream",
  1167. "text": [
  1168. "Before change: ['hard rock', 10, 1.2]\n",
  1169. "After change: [10, 1.2]\n"
  1170. ]
  1171. }
  1172. ],
  1173. "source": [
  1174. "print('Before change:', A)\n",
  1175. "del(A[0])\n",
  1176. "print('After change:', A)"
  1177. ]
  1178. },
  1179. {
  1180. "cell_type": "code",
  1181. "execution_count": 116,
  1182. "metadata": {},
  1183. "outputs": [
  1184. {
  1185. "data": {
  1186. "text/plain": [
  1187. "['hard', 'rock']"
  1188. ]
  1189. },
  1190. "execution_count": 116,
  1191. "metadata": {},
  1192. "output_type": "execute_result"
  1193. }
  1194. ],
  1195. "source": [
  1196. "'hard rock'.split()"
  1197. ]
  1198. },
  1199. {
  1200. "cell_type": "code",
  1201. "execution_count": 117,
  1202. "metadata": {},
  1203. "outputs": [
  1204. {
  1205. "data": {
  1206. "text/plain": [
  1207. "['Michael Jackson', 10.2, ['pop', 10]]"
  1208. ]
  1209. },
  1210. "execution_count": 117,
  1211. "metadata": {},
  1212. "output_type": "execute_result"
  1213. }
  1214. ],
  1215. "source": [
  1216. "L"
  1217. ]
  1218. },
  1219. {
  1220. "cell_type": "code",
  1221. "execution_count": 119,
  1222. "metadata": {},
  1223. "outputs": [
  1224. {
  1225. "ename": "AttributeError",
  1226. "evalue": "'list' object has no attribute 'split'",
  1227. "output_type": "error",
  1228. "traceback": [
  1229. "\u001b[0;31m---------------------------------------------------------------------------\u001b[0m",
  1230. "\u001b[0;31mAttributeError\u001b[0m Traceback (most recent call last)",
  1231. "\u001b[0;32m<ipython-input-119-4268816d7575>\u001b[0m in \u001b[0;36m<module>\u001b[0;34m\u001b[0m\n\u001b[0;32m----> 1\u001b[0;31m \u001b[0mL\u001b[0m\u001b[0;34m.\u001b[0m\u001b[0msplit\u001b[0m\u001b[0;34m(\u001b[0m\u001b[0;34m\",\"\u001b[0m\u001b[0;34m)\u001b[0m\u001b[0;34m\u001b[0m\u001b[0;34m\u001b[0m\u001b[0m\n\u001b[0m",
  1232. "\u001b[0;31mAttributeError\u001b[0m: 'list' object has no attribute 'split'"
  1233. ]
  1234. }
  1235. ],
  1236. "source": [
  1237. "L.split(\",\")"
  1238. ]
  1239. },
  1240. {
  1241. "cell_type": "code",
  1242. "execution_count": 120,
  1243. "metadata": {},
  1244. "outputs": [
  1245. {
  1246. "data": {
  1247. "text/plain": [
  1248. "['A', 'B', 'C', 'D']"
  1249. ]
  1250. },
  1251. "execution_count": 120,
  1252. "metadata": {},
  1253. "output_type": "execute_result"
  1254. }
  1255. ],
  1256. "source": [
  1257. "'A,B,C,D'.split(',')"
  1258. ]
  1259. },
  1260. {
  1261. "cell_type": "code",
  1262. "execution_count": 121,
  1263. "metadata": {},
  1264. "outputs": [
  1265. {
  1266. "name": "stdout",
  1267. "output_type": "stream",
  1268. "text": [
  1269. "A: ['hard rock', 10, 1.2]\n",
  1270. "B: ['hard rock', 10, 1.2]\n"
  1271. ]
  1272. }
  1273. ],
  1274. "source": [
  1275. "A = [\"hard rock\", 10, 1.2]\n",
  1276. "B = A\n",
  1277. "print('A:', A)\n",
  1278. "print('B:', B)"
  1279. ]
  1280. },
  1281. {
  1282. "cell_type": "code",
  1283. "execution_count": 122,
  1284. "metadata": {},
  1285. "outputs": [
  1286. {
  1287. "data": {
  1288. "text/plain": [
  1289. "['hard rock', 10, 1.2]"
  1290. ]
  1291. },
  1292. "execution_count": 122,
  1293. "metadata": {},
  1294. "output_type": "execute_result"
  1295. }
  1296. ],
  1297. "source": [
  1298. "B = A[:]\n",
  1299. "B"
  1300. ]
  1301. },
  1302. {
  1303. "cell_type": "code",
  1304. "execution_count": 123,
  1305. "metadata": {},
  1306. "outputs": [
  1307. {
  1308. "name": "stdout",
  1309. "output_type": "stream",
  1310. "text": [
  1311. "B[0]: hard rock\n",
  1312. "B[0]: hard rock\n"
  1313. ]
  1314. }
  1315. ],
  1316. "source": [
  1317. "print('B[0]:', B[0])\n",
  1318. "A[0] = \"hard rock\"\n",
  1319. "print('B[0]:', B[0])"
  1320. ]
  1321. },
  1322. {
  1323. "cell_type": "code",
  1324. "execution_count": 124,
  1325. "metadata": {},
  1326. "outputs": [
  1327. {
  1328. "data": {
  1329. "text/plain": [
  1330. "[1, 'hello', [1, 2, 3], True]"
  1331. ]
  1332. },
  1333. "execution_count": 124,
  1334. "metadata": {},
  1335. "output_type": "execute_result"
  1336. }
  1337. ],
  1338. "source": [
  1339. "a_list = [1, 'hello', [1, 2, 3] , True]\n",
  1340. "a_list"
  1341. ]
  1342. },
  1343. {
  1344. "cell_type": "code",
  1345. "execution_count": 126,
  1346. "metadata": {},
  1347. "outputs": [
  1348. {
  1349. "data": {
  1350. "text/plain": [
  1351. "'hello'"
  1352. ]
  1353. },
  1354. "execution_count": 126,
  1355. "metadata": {},
  1356. "output_type": "execute_result"
  1357. }
  1358. ],
  1359. "source": [
  1360. "a_list[1]"
  1361. ]
  1362. },
  1363. {
  1364. "cell_type": "code",
  1365. "execution_count": 128,
  1366. "metadata": {},
  1367. "outputs": [
  1368. {
  1369. "data": {
  1370. "text/plain": [
  1371. "['hello', [1, 2, 3], True]"
  1372. ]
  1373. },
  1374. "execution_count": 128,
  1375. "metadata": {},
  1376. "output_type": "execute_result"
  1377. }
  1378. ],
  1379. "source": [
  1380. "a_list[1:4]"
  1381. ]
  1382. },
  1383. {
  1384. "cell_type": "code",
  1385. "execution_count": 146,
  1386. "metadata": {},
  1387. "outputs": [
  1388. {
  1389. "data": {
  1390. "text/plain": [
  1391. "([2, 1, 'd', [1, 'a', 2, 1, 'd']], [1, 'a', 2, 1, 'd'])"
  1392. ]
  1393. },
  1394. "execution_count": 146,
  1395. "metadata": {},
  1396. "output_type": "execute_result"
  1397. }
  1398. ],
  1399. "source": [
  1400. "A = [1, 'a']\n",
  1401. "B = [2, 1, 'd']\n",
  1402. "A.extend(B)\n",
  1403. "A\n",
  1404. "B.append(A)\n",
  1405. "B,A"
  1406. ]
  1407. },
  1408. {
  1409. "cell_type": "code",
  1410. "execution_count": 138,
  1411. "metadata": {},
  1412. "outputs": [
  1413. {
  1414. "data": {
  1415. "text/plain": [
  1416. "['Michael Jackson', 10.2, 'pop', 10]"
  1417. ]
  1418. },
  1419. "execution_count": 138,
  1420. "metadata": {},
  1421. "output_type": "execute_result"
  1422. }
  1423. ],
  1424. "source": [
  1425. "L = [ \"Michael Jackson\", 10.2]\n",
  1426. "L.extend(['pop', 10])\n",
  1427. "L"
  1428. ]
  1429. },
  1430. {
  1431. "cell_type": "code",
  1432. "execution_count": 147,
  1433. "metadata": {},
  1434. "outputs": [],
  1435. "source": [
  1436. "A=((1),[2,3],[4])"
  1437. ]
  1438. },
  1439. {
  1440. "cell_type": "code",
  1441. "execution_count": 148,
  1442. "metadata": {},
  1443. "outputs": [
  1444. {
  1445. "data": {
  1446. "text/plain": [
  1447. "[4]"
  1448. ]
  1449. },
  1450. "execution_count": 148,
  1451. "metadata": {},
  1452. "output_type": "execute_result"
  1453. }
  1454. ],
  1455. "source": [
  1456. "A[2]"
  1457. ]
  1458. },
  1459. {
  1460. "cell_type": "code",
  1461. "execution_count": 149,
  1462. "metadata": {},
  1463. "outputs": [
  1464. {
  1465. "data": {
  1466. "text/plain": [
  1467. "4"
  1468. ]
  1469. },
  1470. "execution_count": 149,
  1471. "metadata": {},
  1472. "output_type": "execute_result"
  1473. }
  1474. ],
  1475. "source": [
  1476. "A[2][0]"
  1477. ]
  1478. },
  1479. {
  1480. "cell_type": "code",
  1481. "execution_count": 150,
  1482. "metadata": {},
  1483. "outputs": [
  1484. {
  1485. "data": {
  1486. "text/plain": [
  1487. "['A', 'B', 'C', 'D']"
  1488. ]
  1489. },
  1490. "execution_count": 150,
  1491. "metadata": {},
  1492. "output_type": "execute_result"
  1493. }
  1494. ],
  1495. "source": [
  1496. "'A,B,C,D'.split(',')"
  1497. ]
  1498. },
  1499. {
  1500. "cell_type": "code",
  1501. "execution_count": 1,
  1502. "metadata": {},
  1503. "outputs": [],
  1504. "source": [
  1505. "dict1= {\"key\":1, \"key2\": \"hello\"}"
  1506. ]
  1507. },
  1508. {
  1509. "cell_type": "code",
  1510. "execution_count": 2,
  1511. "metadata": {},
  1512. "outputs": [
  1513. {
  1514. "data": {
  1515. "text/plain": [
  1516. "{'key': 1, 'key2': 'hello'}"
  1517. ]
  1518. },
  1519. "execution_count": 2,
  1520. "metadata": {},
  1521. "output_type": "execute_result"
  1522. }
  1523. ],
  1524. "source": [
  1525. "dict1"
  1526. ]
  1527. },
  1528. {
  1529. "cell_type": "code",
  1530. "execution_count": 3,
  1531. "metadata": {},
  1532. "outputs": [
  1533. {
  1534. "data": {
  1535. "text/plain": [
  1536. "{'key1': 1,\n",
  1537. " 'key2': '2',\n",
  1538. " 'key3': [3, 3, 3],\n",
  1539. " 'key4': (4, 4, 4),\n",
  1540. " 'key5': 5,\n",
  1541. " (0, 1): 6}"
  1542. ]
  1543. },
  1544. "execution_count": 3,
  1545. "metadata": {},
  1546. "output_type": "execute_result"
  1547. }
  1548. ],
  1549. "source": [
  1550. "Dict = {\"key1\": 1, \"key2\": \"2\", \"key3\": [3, 3, 3], \"key4\": (4, 4, 4), ('key5'): 5, (0, 1): 6}\n",
  1551. "Dict"
  1552. ]
  1553. },
  1554. {
  1555. "cell_type": "code",
  1556. "execution_count": 7,
  1557. "metadata": {},
  1558. "outputs": [
  1559. {
  1560. "data": {
  1561. "text/plain": [
  1562. "1"
  1563. ]
  1564. },
  1565. "execution_count": 7,
  1566. "metadata": {},
  1567. "output_type": "execute_result"
  1568. }
  1569. ],
  1570. "source": [
  1571. "Dict[\"key1\"]"
  1572. ]
  1573. },
  1574. {
  1575. "cell_type": "code",
  1576. "execution_count": 8,
  1577. "metadata": {},
  1578. "outputs": [
  1579. {
  1580. "data": {
  1581. "text/plain": [
  1582. "6"
  1583. ]
  1584. },
  1585. "execution_count": 8,
  1586. "metadata": {},
  1587. "output_type": "execute_result"
  1588. }
  1589. ],
  1590. "source": [
  1591. "Dict[(0, 1)]"
  1592. ]
  1593. },
  1594. {
  1595. "cell_type": "code",
  1596. "execution_count": 9,
  1597. "metadata": {},
  1598. "outputs": [
  1599. {
  1600. "data": {
  1601. "text/plain": [
  1602. "{'Thriller': '1982',\n",
  1603. " 'Back in Black': '1980',\n",
  1604. " 'The Dark Side of the Moon': '1973',\n",
  1605. " 'The Bodyguard': '1992',\n",
  1606. " 'Bat Out of Hell': '1977',\n",
  1607. " 'Their Greatest Hits (1971-1975)': '1976',\n",
  1608. " 'Saturday Night Fever': '1977',\n",
  1609. " 'Rumours': '1977'}"
  1610. ]
  1611. },
  1612. "execution_count": 9,
  1613. "metadata": {},
  1614. "output_type": "execute_result"
  1615. }
  1616. ],
  1617. "source": [
  1618. "release_year_dict = {\"Thriller\": \"1982\", \"Back in Black\": \"1980\", \\\n",
  1619. " \"The Dark Side of the Moon\": \"1973\", \"The Bodyguard\": \"1992\", \\\n",
  1620. " \"Bat Out of Hell\": \"1977\", \"Their Greatest Hits (1971-1975)\": \"1976\", \\\n",
  1621. " \"Saturday Night Fever\": \"1977\", \"Rumours\": \"1977\"}\n",
  1622. "release_year_dict"
  1623. ]
  1624. },
  1625. {
  1626. "cell_type": "code",
  1627. "execution_count": 10,
  1628. "metadata": {},
  1629. "outputs": [
  1630. {
  1631. "data": {
  1632. "text/plain": [
  1633. "'1982'"
  1634. ]
  1635. },
  1636. "execution_count": 10,
  1637. "metadata": {},
  1638. "output_type": "execute_result"
  1639. }
  1640. ],
  1641. "source": [
  1642. "release_year_dict['Thriller']"
  1643. ]
  1644. },
  1645. {
  1646. "cell_type": "code",
  1647. "execution_count": 11,
  1648. "metadata": {},
  1649. "outputs": [
  1650. {
  1651. "data": {
  1652. "text/plain": [
  1653. "dict_keys(['Thriller', 'Back in Black', 'The Dark Side of the Moon', 'The Bodyguard', 'Bat Out of Hell', 'Their Greatest Hits (1971-1975)', 'Saturday Night Fever', 'Rumours'])"
  1654. ]
  1655. },
  1656. "execution_count": 11,
  1657. "metadata": {},
  1658. "output_type": "execute_result"
  1659. }
  1660. ],
  1661. "source": [
  1662. "release_year_dict.keys() "
  1663. ]
  1664. },
  1665. {
  1666. "cell_type": "code",
  1667. "execution_count": 12,
  1668. "metadata": {},
  1669. "outputs": [
  1670. {
  1671. "data": {
  1672. "text/plain": [
  1673. "dict_values(['1982', '1980', '1973', '1992', '1977', '1976', '1977', '1977'])"
  1674. ]
  1675. },
  1676. "execution_count": 12,
  1677. "metadata": {},
  1678. "output_type": "execute_result"
  1679. }
  1680. ],
  1681. "source": [
  1682. "release_year_dict.values() "
  1683. ]
  1684. },
  1685. {
  1686. "cell_type": "code",
  1687. "execution_count": 13,
  1688. "metadata": {},
  1689. "outputs": [
  1690. {
  1691. "data": {
  1692. "text/plain": [
  1693. "{'Thriller': '1982',\n",
  1694. " 'Back in Black': '1980',\n",
  1695. " 'The Dark Side of the Moon': '1973',\n",
  1696. " 'The Bodyguard': '1992',\n",
  1697. " 'Bat Out of Hell': '1977',\n",
  1698. " 'Their Greatest Hits (1971-1975)': '1976',\n",
  1699. " 'Saturday Night Fever': '1977',\n",
  1700. " 'Rumours': '1977',\n",
  1701. " 'Graduation': '2007'}"
  1702. ]
  1703. },
  1704. "execution_count": 13,
  1705. "metadata": {},
  1706. "output_type": "execute_result"
  1707. }
  1708. ],
  1709. "source": [
  1710. "release_year_dict['Graduation'] = '2007'\n",
  1711. "release_year_dict"
  1712. ]
  1713. },
  1714. {
  1715. "cell_type": "code",
  1716. "execution_count": 14,
  1717. "metadata": {},
  1718. "outputs": [
  1719. {
  1720. "data": {
  1721. "text/plain": [
  1722. "{'Back in Black': '1980',\n",
  1723. " 'The Dark Side of the Moon': '1973',\n",
  1724. " 'The Bodyguard': '1992',\n",
  1725. " 'Bat Out of Hell': '1977',\n",
  1726. " 'Their Greatest Hits (1971-1975)': '1976',\n",
  1727. " 'Saturday Night Fever': '1977',\n",
  1728. " 'Rumours': '1977'}"
  1729. ]
  1730. },
  1731. "execution_count": 14,
  1732. "metadata": {},
  1733. "output_type": "execute_result"
  1734. }
  1735. ],
  1736. "source": [
  1737. "del(release_year_dict['Thriller'])\n",
  1738. "del(release_year_dict['Graduation'])\n",
  1739. "release_year_dict"
  1740. ]
  1741. },
  1742. {
  1743. "cell_type": "code",
  1744. "execution_count": 15,
  1745. "metadata": {},
  1746. "outputs": [
  1747. {
  1748. "data": {
  1749. "text/plain": [
  1750. "True"
  1751. ]
  1752. },
  1753. "execution_count": 15,
  1754. "metadata": {},
  1755. "output_type": "execute_result"
  1756. }
  1757. ],
  1758. "source": [
  1759. "'The Bodyguard' in release_year_dict"
  1760. ]
  1761. },
  1762. {
  1763. "cell_type": "code",
  1764. "execution_count": 16,
  1765. "metadata": {},
  1766. "outputs": [
  1767. {
  1768. "data": {
  1769. "text/plain": [
  1770. "{'The Bodyguard': '1992', 'Saturday Night Fever': '1977'}"
  1771. ]
  1772. },
  1773. "execution_count": 16,
  1774. "metadata": {},
  1775. "output_type": "execute_result"
  1776. }
  1777. ],
  1778. "source": [
  1779. "soundtrack_dic = {\"The Bodyguard\":\"1992\", \"Saturday Night Fever\":\"1977\"}\n",
  1780. "soundtrack_dic"
  1781. ]
  1782. },
  1783. {
  1784. "cell_type": "code",
  1785. "execution_count": 17,
  1786. "metadata": {},
  1787. "outputs": [
  1788. {
  1789. "data": {
  1790. "text/plain": [
  1791. "dict_keys(['The Bodyguard', 'Saturday Night Fever'])"
  1792. ]
  1793. },
  1794. "execution_count": 17,
  1795. "metadata": {},
  1796. "output_type": "execute_result"
  1797. }
  1798. ],
  1799. "source": [
  1800. "soundtrack_dic.keys()"
  1801. ]
  1802. },
  1803. {
  1804. "cell_type": "code",
  1805. "execution_count": 18,
  1806. "metadata": {},
  1807. "outputs": [
  1808. {
  1809. "data": {
  1810. "text/plain": [
  1811. "dict_values(['1992', '1977'])"
  1812. ]
  1813. },
  1814. "execution_count": 18,
  1815. "metadata": {},
  1816. "output_type": "execute_result"
  1817. }
  1818. ],
  1819. "source": [
  1820. "soundtrack_dic.values()"
  1821. ]
  1822. },
  1823. {
  1824. "cell_type": "code",
  1825. "execution_count": null,
  1826. "metadata": {},
  1827. "outputs": [],
  1828. "source": []
  1829. }
  1830. ],
  1831. "metadata": {
  1832. "kernelspec": {
  1833. "display_name": "Python 3",
  1834. "language": "python",
  1835. "name": "python3"
  1836. },
  1837. "language_info": {
  1838. "codemirror_mode": {
  1839. "name": "ipython",
  1840. "version": 3
  1841. },
  1842. "file_extension": ".py",
  1843. "mimetype": "text/x-python",
  1844. "name": "python",
  1845. "nbconvert_exporter": "python",
  1846. "pygments_lexer": "ipython3",
  1847. "version": "3.6.8"
  1848. }
  1849. },
  1850. "nbformat": 4,
  1851. "nbformat_minor": 2
  1852. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement