What's great about Computer Science? Other than Computer Science Posted: 01 Jul 2021 06:26 AM PDT So I'll be studying CS at University soon. I'm excited, and at the moment I want to consume myself with CS related content. I watch all the 'day in the life' videos (highly fabricated, I know), vlogs etc about the subject. I'm not struggling with motivation, I just want to find out more about CS, that isn't actually study based, I think I'd crash if I tried to learn another thing at the moment. With that being said, what do you enjoy about CS, that isn't actually 'work' related? submitted by /u/coolSnipesMore [link] [comments] |
$102M to Continue Building the Next Web, Together Posted: 24 Jun 2021 03:40 AM PDT |
How are computational neuroscience and machine learning overalapping? Posted: 22 Jun 2021 08:02 PM PDT Hi, I am an undergrad with a background in neuroscience and math. I have been very much interested in the problem of AGI, how the human mind even exists, and how the brain fundamentally works. I think computational neuroscience is making a lot of headwinds on these questions. Recently, I have been perusing some ML labs that have been working on the problems within cognitive neuroscience as well. I was wondering how these fields interact. If I do a PhD in comp neuro, is there a possibility for me to work in the ML and AI field if teach myself a lot of these concepts and do research that uses these concepts? Btw I get these are hard questions to answer and I won't be able to answer them completely and probably work on a small part to answer it. I am ok with that. submitted by /u/fallszero_5 [link] [comments] |
Why doesn't the output match the expected one when computing the standard deviation in CPP? Posted: 23 Jun 2021 08:16 PM PDT description and sample: https://imgur.com/a/Vsc9Lp7 here only code for girls.txt #include<iostream> #include<fstream> #include<cctype> #include<iomanip> #include<cmath> #include<sstream> using namespace std; string tolowercase(string s){ for(int i=0;i<s.length();i++){ s[i]=tolower(s[i]); } return s; } int isInArray(string arr[],string target){ for(int i=0;i<100;i++){ stringstream ss; string name; ss<<arr[i]; ss>>name; if(tolowercase(name)==tolowercase(target)){ return i+1; } } return -1; } string namings(string s){ stringstream ss; ss<<s; string str,str2; ss>>str>>str2; return str2; } int main(){ string girls[100]; fstream p("girls.txt"); int i=0; while(p>>girls[i]){ string temp; p>>temp; girls[i]+=" "+temp; i++; } p.close(); while(1){ cout<<"(If you don't want to search name, please input exit!)\n"; cout<<"Enter name: "; string name; cin>>name; if(name=="exit"){ break; } cout<<endl; int index=isInArray(girls,name); if(index==-1){ cout<<name<<" is not ranked among the top 100 girl names.\n\n"; }else{ cout<<name<<" is ranked "<<index<<" in popularity among girls with "<<namings(girls[index-1])<<" namings.\n"; //here start computing standard deviation double u; double sum=0; for(int i=0;i<10;i++){ sum+=stod(namings(girls[index-1+i+1])); } u=sum/10; sum=0; for(int i=0;i<10;i++){ sum+=(stod(namings(girls[index-1+i+1]))-u)*(stod(namings(girls[index-1+i+1]))-u); } double sd=sqrt(sum/10); cout<<"Standard Deviation of the 10 list below this rank : "<<sd<<endl; cout<<endl; } } return 0; } girls.txt Mary 3196385 Patricia 1558407 Jennifer 1468377 Linda 1448303 Elizabeth 1420377 Barbara 1397635 Susan 1103569 Jessica 1046322 Sarah 991910 Karen 986057 Nancy 966867 Lisa 965015 Betty 924629 Margaret 918541 Sandra 873509 Ashley 849297 Kimberly 839796 Emily 830999 Donna 822330 Michelle 812335 Dorothy 811392 Carol 806170 Amanda 773199 Melissa 753994 Deborah 740019 Stephanie 738523 Rebecca 729630 Sharon 720826 Laura 718006 Cynthia 705717 Kathleen 686217 Amy 681397 Shirley 663452 Angela 658968 Helen 618563 Anna 618367 Brenda 606291 Pamela 592696 Nicole 589434 Emma 580610 Samantha 578986 Katherine 571574 Christine 561161 Debra 548280 Rachel 546153 Catherine 542748 Carolyn 540963 Janet 539224 Ruth 538629 Maria 529342 Heather 524166 Diane 515183 Virginia 515088 Julie 506594 Joyce 499340 Victoria 485786 Olivia 481364 Kelly 471621 Christina 471106 Lauren 470902 Joan 467459 Evelyn 461952 Judith 449805 Megan 437647 Cheryl 436882 Andrea 436126 Hannah 431117 Martha 426247 Jacqueline 420505 Frances 414289 Gloria 408565 Ann 407374 Teresa 404253 Kathryn 402613 Sara 400884 Janice 399546 Jean 399416 Alice 396362 Madison 393297 Doris 383158 Tyler 381738 Julia 380836 Judy 377815 Grace 377678 Denise 371269 Amber 370577 Marilyn 369781 Beverly 369669 Danielle 368485 Billy 367426 Sophia 364383 Marie 361371 Diana 359617 Brittany 358850 Natalie 356379 Isabella 354245 Charlotte 347772 Rose 344656 Alexis 340587 Kayla 340511 submitted by /u/hwpcspr [link] [comments] |
Why doesn't the output match the expected one when computing the standard deviation in CPP? Posted: 23 Jun 2021 07:52 PM PDT description and sample: https://imgur.com/a/Vsc9Lp7 here only code for girls.txt #include<iostream> #include<fstream> #include<cctype> #include<iomanip> #include<cmath> #include<sstream> using namespace std; string tolowercase(string s){ for(int i=0;i<s.length();i++){ s[i]=tolower(s[i]); } return s; } int isInArray(string arr[],string target){ for(int i=0;i<100;i++){ stringstream ss; string name; ss<<arr[i]; ss>>name; if(tolowercase(name)==tolowercase(target)){ return i+1; } } return -1; } string namings(string s){ stringstream ss; ss<<s; string str,str2; ss>>str>>str2; return str2; } int main(){ string girls[100]; fstream p("girls.txt"); int i=0; while(p>>girls[i]){ string temp; p>>temp; girls[i]+=" "+temp; i++; } p.close(); while(1){ cout<<"(If you don't want to search name, please input exit!)\n"; cout<<"Enter name: "; string name; cin>>name; if(name=="exit"){ break; } cout<<endl; int index=isInArray(girls,name); if(index==-1){ cout<<name<<" is not ranked among the top 100 girl names.\n\n"; }else{ cout<<name<<" is ranked "<<index<<" in popularity among girls with "<<namings(girls[index-1])<<" namings.\n"; //here start computing standard deviation double u; double sum=0; for(int i=0;i<10;i++){ sum+=stod(namings(girls[index-1+i+1])); } u=sum/10; sum=0; for(int i=0;i<10;i++){ sum+=(stod(namings(girls[index-1+i+1]))-u)*(stod(namings(girls[index-1+i+1]))-u); } double sd=sqrt(sum/10); cout<<"Standard Deviation of the 10 list below this rank : "<<sd<<endl; cout<<endl; } } return 0; } girls.txt Mary 3196385 Patricia 1558407 Jennifer 1468377 Linda 1448303 Elizabeth 1420377 Barbara 1397635 Susan 1103569 Jessica 1046322 Sarah 991910 Karen 986057 Nancy 966867 Lisa 965015 Betty 924629 Margaret 918541 Sandra 873509 Ashley 849297 Kimberly 839796 Emily 830999 Donna 822330 Michelle 812335 Dorothy 811392 Carol 806170 Amanda 773199 Melissa 753994 Deborah 740019 Stephanie 738523 Rebecca 729630 Sharon 720826 Laura 718006 Cynthia 705717 Kathleen 686217 Amy 681397 Shirley 663452 Angela 658968 Helen 618563 Anna 618367 Brenda 606291 Pamela 592696 Nicole 589434 Emma 580610 Samantha 578986 Katherine 571574 Christine 561161 Debra 548280 Rachel 546153 Catherine 542748 Carolyn 540963 Janet 539224 Ruth 538629 Maria 529342 Heather 524166 Diane 515183 Virginia 515088 Julie 506594 Joyce 499340 Victoria 485786 Olivia 481364 Kelly 471621 Christina 471106 Lauren 470902 Joan 467459 Evelyn 461952 Judith 449805 Megan 437647 Cheryl 436882 Andrea 436126 Hannah 431117 Martha 426247 Jacqueline 420505 Frances 414289 Gloria 408565 Ann 407374 Teresa 404253 Kathryn 402613 Sara 400884 Janice 399546 Jean 399416 Alice 396362 Madison 393297 Doris 383158 Tyler 381738 Julia 380836 Judy 377815 Grace 377678 Denise 371269 Amber 370577 Marilyn 369781 Beverly 369669 Danielle 368485 Billy 367426 Sophia 364383 Marie 361371 Diana 359617 Brittany 358850 Natalie 356379 Isabella 354245 Charlotte 347772 Rose 344656 Alexis 340587 Kayla 340511 submitted by /u/hwpcspr [link] [comments] |
My kali is just stuck at the time screen, how to fix this? Posted: 22 Jun 2021 10:50 PM PDT |
The Marvelous Journey of a Bit Posted: 20 Jun 2021 10:21 PM PDT |
The man, The myth, The legend. Posted: 20 Jun 2021 03:20 AM PDT |
NightCode Summer Hackathon 2021 Posted: 19 Jun 2021 03:55 PM PDT NightCode's Summer Hackathon 2021 is a two day (48 hour) event managed by the non-profit organization NightCode. NightCode is a student-led, non-profit organization based in Dallas, Texas that aims to establish a community where we can spread enthusiasm and knowledge about Computer Science and technology through various events such as hackathons, workshops, guest talks and courses. This hackathon is for middle and high school students of all experience levels. Teams have a maximum capacity of 4 people. Our theme will be announced during our Opening Ceremony. We have a total prize pool of $1850 made up of prizes, merch and participation awards. This hackathon is from July 9th to July 11th. devpost: https://nightcode-2021.devpost.com/ website: https://nightcode.vercel.app/ submitted by /u/TheImmortal071 [link] [comments] |
No comments:
Post a Comment