Advertisement
Guest User

Untitled

a guest
Jul 18th, 2019
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.62 KB | None | 0 0
  1. {
  2. "cells": [
  3. {
  4. "cell_type": "code",
  5. "execution_count": 1,
  6. "metadata": {},
  7. "outputs": [],
  8. "source": [
  9. "name='Lizz'"
  10. ]
  11. },
  12. {
  13. "cell_type": "code",
  14. "execution_count": 2,
  15. "metadata": {},
  16. "outputs": [
  17. {
  18. "name": "stdout",
  19. "output_type": "stream",
  20. "text": [
  21. "Li\n"
  22. ]
  23. }
  24. ],
  25. "source": [
  26. "print(name[0:2])"
  27. ]
  28. },
  29. {
  30. "cell_type": "code",
  31. "execution_count": 3,
  32. "metadata": {},
  33. "outputs": [],
  34. "source": [
  35. "A='1934567'"
  36. ]
  37. },
  38. {
  39. "cell_type": "code",
  40. "execution_count": 4,
  41. "metadata": {},
  42. "outputs": [
  43. {
  44. "data": {
  45. "text/plain": [
  46. "'946'"
  47. ]
  48. },
  49. "execution_count": 4,
  50. "metadata": {},
  51. "output_type": "execute_result"
  52. }
  53. ],
  54. "source": [
  55. "A[1::2]"
  56. ]
  57. },
  58. {
  59. "cell_type": "code",
  60. "execution_count": 5,
  61. "metadata": {},
  62. "outputs": [
  63. {
  64. "data": {
  65. "text/plain": [
  66. "'12'"
  67. ]
  68. },
  69. "execution_count": 5,
  70. "metadata": {},
  71. "output_type": "execute_result"
  72. }
  73. ],
  74. "source": [
  75. "'1'+'2'"
  76. ]
  77. },
  78. {
  79. "cell_type": "code",
  80. "execution_count": null,
  81. "metadata": {},
  82. "outputs": [],
  83. "source": []
  84. }
  85. ],
  86. "metadata": {
  87. "kernelspec": {
  88. "display_name": "Python 3",
  89. "language": "python",
  90. "name": "python3"
  91. },
  92. "language_info": {
  93. "codemirror_mode": {
  94. "name": "ipython",
  95. "version": 3
  96. },
  97. "file_extension": ".py",
  98. "mimetype": "text/x-python",
  99. "name": "python",
  100. "nbconvert_exporter": "python",
  101. "pygments_lexer": "ipython3",
  102. "version": "3.6.7"
  103. }
  104. },
  105. "nbformat": 4,
  106. "nbformat_minor": 4
  107. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement