{ "nbformat": 4, "nbformat_minor": 0, "metadata": { "colab": { "provenance": [] }, "kernelspec": { "name": "python3", "display_name": "Python 3" }, "language_info": { "name": "python" } }, "cells": [ { "cell_type": "code", "execution_count": 24, "metadata": { "colab": { "base_uri": "https://localhost:8080/" }, "id": "Cqh1q7nRxxKa", "outputId": "d9891e4f-5352-48bb-8a45-26d52f701ee1" }, "outputs": [ { "output_type": "stream", "name": "stdout", "text": [ "dot605 (717) 466-1813\n" ] } ], "source": [ "import random\n", "\n", "def generate_phone_number():\n", " area_code = random.randint(100,999)\n", " exchange_code = random.randint(100,999)\n", " subscriber_number = random.randint(1000,9999)\n", " return f\"({area_code}) {exchange_code}-{subscriber_number}\"\n", "\n", "phone_number = generate_phone_number()\n", "print(\"dot605\", generate_phone_number())" ] } ] }