Skip to content

Metapost #414

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 4 commits into
base: gh-pages
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
69 changes: 69 additions & 0 deletions _posts/2014-03-16-pipesexercisesesbabykav.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,69 @@
---
layout: post
author: ethan
date: 2014-03-16
title: Pipes and Stuffs
---

##Process
So doing these exercises I had to do them a couple of times to fully understand what they were doing. I also had to re-read some of the things to really understand what the heck was going on too. One thing that I got stuck on was sorting. Whenever I would sort and then try to get the head, it would always give me something that I wasn't expecting. Then after re-reading and trying to do EVERYTHING over again at least twice, I figured out I was forgetting to add the -n to make it sort numerically. Sorting it numerically gave me the right output.

##Number 1
sorting with -n sorts it numerically.

##Number 2
they both count the number of lines. The difference is the "<". The "<" tells it to read from a file instead from standard input. The first one tells it to read from the file and the second one tells it to read from the standard input and then give the output of line numbers.

##Number 3
I think that it only removes adjacent duplicates for a couple of different reasons.
1) It only removes them becasue people might have duplicates for a reason. Sometimes adjacent entries could mean that one of the entries was an accident. So removing entries that are next to each other removes one of the mistakes. Othe entries that aren't beside each other could mean that they are there for a reason.
2) It could just take too long for it to try to find other duplicates that aren't adjacent. There is a ton of data in these things and it could take too much time and energy to find repititions that aren't right beside each other.
3) Sometimes the system can make copies on accident and the same file just shows up. It doesn't need to be there that many times and can be deleted to save space.
4) To maybe get it to where it can find all of the duplicates you can compine it with this code: "sort salmon.txt | uniq". doing this will reorder and sort the list to put all of the duplicates so that it can actually find all of the duplicates that are right next to each other.

##Number 4
Okay so this took a little thinking, but I think I've got it.

We started with this file: animals.txt

```
2012-11-05,deer
2012-11-05,rabbit
2012-11-05,raccoon
2012-11-06,rabbit
2012-11-06,deer
2012-11-06,fox
2012-11-07,rabbit
2012-11-07,bear
```
head -5 gives us the first 5 lines of animals.txt

```
2012-11-05,deer
2012-11-05,rabbit
2012-11-05,raccoon
2012-11-06,rabbit
2012-11-06,deer
```

Then tail -3 tells us to get the last three lines of that

```
2012-11-05,raccoon
2012-11-06,rabbit
2012-11-06,deer
```

then sort -r tells us to reverse that order

```
2012-11-06,deer
2012-11-06,rabbit
2012-11-05,raccoon
```

and then that saves in the file final.txt

##Number 5
cut -d , -f 2 animals.txt | sort | uniq
this would sort it and then it would remove any duplicates.
15 changes: 15 additions & 0 deletions _posts/2014-03-19-ncaapost.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
---
layout: post
author:
- ethan
- grant
date: 2014-03-19
title: Working with Grant
---

For this exercise, I had to opportunity to work with Grant. Since he was running around the room while I wrote this, this is the babykav speaking.

Here is the link to the added NCSU file: https://github.com/silshack/NCAA/pull/26
Here is the link to the added St. Louis file: https://github.com/silshack/NCAA/pull/21

Working with Grant wasn't too bad haha. He seemed to know what he was doing. He also seemed a little distracted. Apparently he's popular in this class. One thing I did have an issue with was the fact that I didn't know which pull request to close. So I closed both of them. Both had the information that was needed. So I just went ahead and closed them both and deleted the branch. Grant said it was okay...so I guess that's okay.
33 changes: 33 additions & 0 deletions _posts/2014-04-27-ethansmetapost.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
---
layout: post
author: ethan
title: Ethans metapost
date: 2014-04-27
---

here are the links to the three meetups i went to this semester:
https://plus.google.com/102796931182909759537/posts/BirtejkvNwy
https://plus.google.com/102796931182909759537/posts/MnqEo2gSrxR
https://plus.google.com/102796931182909759537/posts/ESvgjJGW4SR

i had the opportunity to go to three completely different meetups. the first meetup was an open meeting at splatspace.
i went to their headquarters in durham, heard what they were all working on, talked to some of the guys, and got a tour of everything that was going on.
the second meetup i went to was NSCoder Night - Durham/Chapel Hill - Weekly Hack Night. this was a very laid back atmosphere at a bar.
the third meetup i went to was a bunch of college students doing some coding for class. very very different than the other two.

i have a couple of key take aways from going to these meetups.

one of the biggest ones is that coders can all be very different. going in, i thought that all legit coders were going to be really nerdy.
going into these meetups and coming out having a normal conversation with people and then being able to talk about what they were working on was really cool.
it's really taught me to not going in with expectations. expectations will only get me in trouble in these sorts of situations.

one of the other key take aways is that you don't have to be getting paid to be working on something really cool.
some of the people that i went and met up with were working on projects just for fun. one of the guys at the NSCoders Night had created an app for soccer refs.
he did that for fun. not really to make a ton of money. but then the students were having to do it becasue they were required to for class. a little different atmosphere.

and i guess my last observation is that coding can actualy be fun. these people were having fun. they had created communities of like people and were just coding for fun.
if you can find something that you can do with a friend, why not?

anyways, i actually really enjoyed going to meetups.

babykav out