From a04de22751a47c9b04f4607bc30ad85f050abe9f Mon Sep 17 00:00:00 2001 From: rakesh Date: Mon, 23 Apr 2018 09:55:18 +0530 Subject: [PATCH] mysql database connectivity --- database_complete.py => database/database_complete.py | 0 delete_record.py => database/delete_record.py | 0 insert_row.py => database/insert_row.py | 0 mysql_connection.py => database/mysql_connection.py | 0 select_command.py => database/select_command.py | 0 multiple_assignment.py | 2 ++ regular/digit.py | 4 ++++ 7 files changed, 6 insertions(+) rename database_complete.py => database/database_complete.py (100%) rename delete_record.py => database/delete_record.py (100%) rename insert_row.py => database/insert_row.py (100%) rename mysql_connection.py => database/mysql_connection.py (100%) rename select_command.py => database/select_command.py (100%) create mode 100644 multiple_assignment.py create mode 100644 regular/digit.py diff --git a/database_complete.py b/database/database_complete.py similarity index 100% rename from database_complete.py rename to database/database_complete.py diff --git a/delete_record.py b/database/delete_record.py similarity index 100% rename from delete_record.py rename to database/delete_record.py diff --git a/insert_row.py b/database/insert_row.py similarity index 100% rename from insert_row.py rename to database/insert_row.py diff --git a/mysql_connection.py b/database/mysql_connection.py similarity index 100% rename from mysql_connection.py rename to database/mysql_connection.py diff --git a/select_command.py b/database/select_command.py similarity index 100% rename from select_command.py rename to database/select_command.py diff --git a/multiple_assignment.py b/multiple_assignment.py new file mode 100644 index 0000000..3c6dab4 --- /dev/null +++ b/multiple_assignment.py @@ -0,0 +1,2 @@ +a,b,c = 10,20,30 +print("\n Multiple assignment operator \n a = {} \n B = {} \n c= {}".format(a,b,c)) \ No newline at end of file diff --git a/regular/digit.py b/regular/digit.py new file mode 100644 index 0000000..e1fe54f --- /dev/null +++ b/regular/digit.py @@ -0,0 +1,4 @@ +import re +phoneNumRegex = re.compile(r'\d\d\d-\d\d\d-\d\d\d\d') +mo = phoneNumRegex.search('My number is 415-555-4242.') +print('Phone number found: ' + mo.group()) \ No newline at end of file