text
stringlengths
1
81
start
float64
0
10.1k
duration
float64
0
24.9
email address but name this time and
4,447.96
3.48
we're going to hope that they type in
4,450.199
4.52
their name properly like David ma but
4,451.44
4.799
some users might be in the habit for
4,454.719
3.161
whatever reason of typing their name
4,456.239
3.681
backwards if you will with a comma such
4,457.88
6.72
as ma comma David instead now it's fine
4,459.92
6.6
because both both are clearly as
4,464.6
3.8
readable to the human but if you want to
4,466.52
4
standardize how those names are stored
4,468.4
4.56
in your system perhaps a database or CSV
4,470.52
4.24
file or something else it would be nice
4,472.96
3.96
to at least standardize or canonicalize
4,474.76
3.8
the format in which you're storing your
4,476.92
3.759
data so that if you print out the user's
4,478.56
4.119
name it's always the same format David
4,480.679
4.761
men and there's no commas or backwards
4,482.679
5.401
to it so let's go ahead and do something
4,485.44
4.04
familiar let's go ahead and give myself
4,488.08
3.599
a variable called name and set it equal
4,489.48
3.96
to the return value of input asking the
4,491.679
3.96
user as we've done many times what's
4,493.44
4.12
your name question mark I'm going to go
4,495.639
3.721
ahead and proactively at least clean up
4,497.56
4.119
some messiness as we keep doing here by
4,499.36
3.72
just stripping off any leading or
4,501.679
2.881
trailing whites space just in case the
4,503.08
3.559
user accidentally hits the space bar we
4,504.56
4.44
don't want that ultimately in our data
4,506.639
4.721
set and now let me go ahead and do this
4,509
3.76
as we've done before let me just go
4,511.36
3.24
ahead quickly and print out just to make
4,512.76
4.28
sure I'm off to the right start hello
4,514.6
4.559
and then in curly braces name so making
4,517.04
5.159
an F string to format hello comma name
4,519.159
4.401
now let me go ahead and clear my screen
4,522.199
3.921
and run python a format up Pi let me
4,523.56
4.36
behave and type in my name as I normally
4,526.12
4.519
would David space ma enter and I think
4,527.92
4.88
the output looks pretty good it looks as
4,530.639
4.52
expected grammatically let me now go
4,532.8
4.72
ahead though and play this game again
4,535.159
3.601
but this time maybe because I'm not
4,537.52
2.52
thinking or I'm just in the habit of
4,538.76
3.879
doing last name comma first I do mein
4,540.04
5.4
comma David and hit enter all right well
4,542.639
5.241
this now is is weird even though the
4,545.44
4.239
program is just spitting out exactly
4,547.88
4.319
what I typed in arguably this is not
4,549.679
4.241
close to correct at least grammatically
4,552.199
4.921
it should really say hello David ma now
4,553.92
4.759
maybe I could have some if conditions
4,557.12
3.119
and I could just reject the users's
4,558.679
3.641
input if they type a comma or get their
4,560.239
4.121
names backwards somehow but that's going
4,562.32
4.359
to be uh too little too late if the user
4,564.36
4.72
has already submitted a form online and
4,566.679
4.601
I already have the data and now I need
4,569.08
3.84
to go in and clean it up and it's not
4,571.28
3.32
going to be fun to go through manually
4,572.92
3.64
in Google spreadsheets or apple numbers
4,574.6
4.76
or Microsoft Excel and manually fix a
4,576.56
4.52
lot of people's names to get rid of the
4,579.36
3.56
commas and move the first name before
4,581.08
5
the last as is conventional in the us so
4,582.92
5
let's do this it could be a little
4,586.08
3.76
fragile but let's like let's start to
4,587.92
2.92
express ourselves a little
4,589.84
3.6
programmatically here and ask this if
4,590.84
6
there is a comma in the person's name
4,593.44
5.32
which is pythonic I'm just asking the
4,596.84
4.04
question is this shorter string in this
4,598.76
4.04
longer string then let me go ahead and
4,600.88
4.04
do this let me go ahead and grab that
4,602.8
5.52
name in the variable split on not just
4,604.92
6.279
the comma but the space after assuming
4,608.32
4.68
the human typed in a space after their
4,611.199
3.721
name and let me go ahead and store the
4,613
4.04
result of that splitting of me comma
4,614.92
4.96
David into two variables let's do last
4,617.04
5.36
comma first again unpacking the sequence
4,619.88
5.64
of values that comes back now let me go
4,622.4
4.88
ahead and reformat the name so I'm going
4,625.52
3.76
to forcibly change the user's name to be
4,627.28
4.399
as I expect so name is actually going to
4,629.28
6.28
be this format string first name then
4,631.679
6.121
last name both in curly braces but
4,635.56
4.36
formatt it together with a single space
4,637.8
4.72
so that I'm overriding the user's input
4,639.92
4.48
and updating my name variable
4,642.52
2.84
accordingly
4,644.4
2.52
for the moment to be clear this program
4,645.36
3.64
is interactive like the users like me
4,646.92
4.48
are typing their name into the program
4,649
5
but imagine the data already is in a CSV
4,651.4
4.44
file it came in from some process like a
4,654
3.92
Google form or something else online you
4,655.84
4.16
could imagine writing code similar to
4,657.92
4.239
this but that maybe goes and reads that
4,660
4.6
file into memory first maybe it's a CSV
4,662.159
5