{ "cells": [ { "cell_type": "code", "execution_count": 2, "metadata": {}, "outputs": [ { "data": { "text/plain": [ "'571500475_01.26 571500475_01 571540303_02.21 571540303_02 571540302_01 571542116_02.164 571542116_02.96 571542116_02 571542115_01.68 571542115_01 571500535_02.18 571500535_02'" ] }, "execution_count": 2, "metadata": {}, "output_type": "execute_result" } ], "source": [ "ST = \"571500535_02 571500535_02.18 571542115_01 571542115_01.68 571542116_02 571542116_02.96 571542116_02.164 571540302_01 571540303_02 571540303_02.21 571500475_01 571500475_01.26\"\n", "elements = ST.split()\n", "reversed_elements = elements[::-1]\n", "reversed_string = \" \".join(reversed_elements)\n", "reversed_string" ] } ], "metadata": { "kernelspec": { "display_name": "rts", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.8.10" } }, "nbformat": 4, "nbformat_minor": 2 }