These are chat archives for FreeCodeCamp/Help

3rd
Oct 2017
Eric Miller
@ericmiller777
Oct 03 2017 01:26
hey guys
Gersho
@Gersho
Oct 03 2017 01:33
hey Eric, thanks @ericmiller777 i learned something sunday thanks to you, did you know that if you are mentionned in a git hub repo, you receive an email ?
CamperBot
@camperbot
Oct 03 2017 01:33
gersho sends brownie points to @ericmiller777 :sparkles: :thumbsup: :sparkles:
:cookie: 309 | @ericmiller777 |http://www.freecodecamp.com/ericmiller777
Gersho
@Gersho
Oct 03 2017 01:33
Screenshot from 2017-10-02 21-33-06.png
Eric Miller
@ericmiller777
Oct 03 2017 01:33
lol
@Gersho thanks for telling me
CamperBot
@camperbot
Oct 03 2017 01:34
ericmiller777 sends brownie points to @gersho :sparkles: :thumbsup: :sparkles:
:cookie: 498 | @gersho |http://www.freecodecamp.com/gersho
Boris
@Boris1011
Oct 03 2017 01:35
 @ericmiller777 your portfolio looks really nice! One thought though, the text is a little bit hard to read for me, but that might just be me...!
Eric Miller
@ericmiller777
Oct 03 2017 01:36
I was going for somthing fancy
Gersho
@Gersho
Oct 03 2017 01:36
looks way more fancy than mine at the very least
mine i decided to go full html/css (no js)
Eric Miller
@ericmiller777
Oct 03 2017 01:37
@Boris1011 thanks for looking at it :)
CamperBot
@camperbot
Oct 03 2017 01:37
ericmiller777 sends brownie points to @boris1011 :sparkles: :thumbsup: :sparkles:
:cookie: 438 | @boris1011 |http://www.freecodecamp.com/boris1011
Eric Miller
@ericmiller777
Oct 03 2017 01:37
mines just bootstrap
Boris
@Boris1011
Oct 03 2017 01:37
@ericmiller777 no worries mate.
Albert Cardona II
@daddycardona
Oct 03 2017 02:02
good evening yall how is everyone :)
@ericmiller777 then only thing that bothers me is when i put the mouse over the links in the bottom you can't see the words so I don't feel sure to click them unless i remove the mouse over and see what is it I am about to click other than that is looks great ;)
Eric Miller
@ericmiller777
Oct 03 2017 02:05
@daddycardona thank you i didnt notice that
CamperBot
@camperbot
Oct 03 2017 02:05
ericmiller777 sends brownie points to @daddycardona :sparkles: :thumbsup: :sparkles:
:cookie: 364 | @daddycardona |http://www.freecodecamp.com/daddycardona
Albert Cardona II
@daddycardona
Oct 03 2017 02:05
thats because I only notice the simplist of mistakes lol
you welcome brother :)
so no js on your site looks awesome
Eric Miller
@ericmiller777
Oct 03 2017 02:11
um i had two add a little
but its not updated yet
also anyone know how to make a button looks likes it was already clicked on load?
:focus
Albert Cardona II
@daddycardona
Oct 03 2017 02:12
Oh I think I had someone ask that let me see if I can remember
Boris
@Boris1011
Oct 03 2017 02:13
@ericmiller777 I tend to use a:hover a:active and a:focus all on one line, although i don't know if that really does much... and I usually have something for a:visited as well
something along those lines......
Albert Cardona II
@daddycardona
Oct 03 2017 02:15
in your class="btn active"
Eric Miller
@ericmiller777
Oct 03 2017 02:15
let me try
Albert Cardona II
@daddycardona
Oct 03 2017 02:16
well the fiddle did not seem as it worked
Eric Miller
@ericmiller777
Oct 03 2017 02:16
@daddycardona thank you but that makes it actibve not focus :P
CamperBot
@camperbot
Oct 03 2017 02:16
ericmiller777 sends brownie points to @daddycardona :sparkles: :thumbsup: :sparkles:
api offline
Eric Miller
@ericmiller777
Oct 03 2017 02:16
its a weird issue
Albert Cardona II
@daddycardona
Oct 03 2017 02:17
autofocus="true"
<div class="btn-group">
    <button class="btn btn-primary" autofocus="true">1</button>
    <button class="btn btn-primary">2</button>
    <button class="btn btn-primary">3</button>
    <button class="btn btn-primary">4</button>
    <button class="btn btn-primary">5</button>
    <button class="btn btn-primary">6</button>
    <button class="btn btn-primary">7</button>
</div>
this worked in a site I believe that is what you are lookin for :)
@ericmiller777
Eric Miller
@ericmiller777
Oct 03 2017 02:20
Thank you
Gersho
@Gersho
Oct 03 2017 02:26
i'm looking for an equivalent to min-height but for fonts
Albert Cardona II
@daddycardona
Oct 03 2017 02:28
what you mean @Gersho
you welcome @ericmiller777 I am just happy I can help :)
Gersho
@Gersho
Oct 03 2017 02:29
something like min-font-size / max-font-size
i love js but my html/css skills are just deplorable
Long Nguyen
@longnt80
Oct 03 2017 02:35
@Gersho you mean responsive font
Gersho
@Gersho
Oct 03 2017 02:36
@longnt80 i tried using vh / vw to have the fond responsive, but it ends up too small on small screens
(or too big on big screen if i try to fix it)
Long Nguyen
@longnt80
Oct 03 2017 02:36
@Gersho you should take a look at this: https://www.smashingmagazine.com/2016/05/fluid-typography/
Gersho
@Gersho
Oct 03 2017 02:37
thanks @longnt80
CamperBot
@camperbot
Oct 03 2017 02:37
gersho sends brownie points to @longnt80 :sparkles: :thumbsup: :sparkles:
:cookie: 574 | @longnt80 |http://www.freecodecamp.com/longnt80
Long Nguyen
@longnt80
Oct 03 2017 02:37
I saw Vitaly Friedman showed that at a Mozilla conference
piteto
@piteto
Oct 03 2017 02:38
This is what materialize does for their responsive font sizing: https://s.codepen.io/anon/pen/XeepJM?editors=0100
Long Nguyen
@longnt80
Oct 03 2017 02:38
@piteto actually, using calc is better for font because you dont have to maintaince so many media queries
piteto
@piteto
Oct 03 2017 02:39
@longnt80 I hadn't heard that before. I wonder why materialize uses all the media queries
Gersho
@Gersho
Oct 03 2017 02:39
@media only screen and (min-width: 480px) {
  .responsive-text {
    font-size: 1.196rem;
  }
}
that's some advanced CSSorcery don't know half of that xD
Long Nguyen
@longnt80
Oct 03 2017 02:40
@Gersho that's just media query and rem
Gersho
@Gersho
Oct 03 2017 02:40
rem i know
Long Nguyen
@longnt80
Oct 03 2017 02:40
@piteto the people at smashing magazine are pretty advanced in term of front end
media queries can become cumbersome
piteto
@piteto
Oct 03 2017 02:41
@longnt80 materialize.css is right up there with foundation and bootstrap though too - maybe it's for browser compatibility
definitely more maintainable to use calc()
Long Nguyen
@longnt80
Oct 03 2017 02:41
@piteto calc is supported from IE9+
piteto
@piteto
Oct 03 2017 02:45
No idea why they do it then, looks like they only support IE10+
Gersho
@Gersho
Oct 03 2017 02:45

after a bit of reading, it seem vh/vw is the way to go but i was missing:

Using viewport-relative units alone comes with some drawbacks. We don’t get precise control over the rate of scale; we don’t have min or max font sizes; and, just like pixels, a declaration might override the user’s font-size preferences. Luckily, there are ways to overcome all of these limitations.

i'm on the edge of my chair waiting to read the rest ;)

piteto
@piteto
Oct 03 2017 02:47
Looks like calc with percentages is broken on IE11
Looks like this wold work though:
html {
  font-size: calc(0.875em + 0.25 * (100vw - 80em) / 40);
  font-size: -webkit-calc(87.5% + 0.25 * (100vw - 8000%) / 40);
}
Long Nguyen
@longnt80
Oct 03 2017 02:49
Gersho
@Gersho
Oct 03 2017 02:49
css + maths, are you trying to murder me ?
Long Nguyen
@longnt80
Oct 03 2017 02:50
@piteto I think the first comment in that article explain why the calc method is not popular
This is all good and well, but what user (minus the devs/designers) are going to actually scale the browser up and down? I think its a great solution but I don’t think the reason you gave it is the reason it should be used. Thanks!
Gersho
@Gersho
Oct 03 2017 02:52
i don't really care about real time resizing, i only want it to display to display properly on all kind of screens, calc( 1 em+1vw) or some equivalent should do the trick for me :)
Gersho
@Gersho
Oct 03 2017 02:53
easy maths, i love that, i'll keep that image around ^^
Long Nguyen
@longnt80
Oct 03 2017 02:54
maybe create a sass mixins for it
Gersho
@Gersho
Oct 03 2017 02:54
i'm not sure i understand what screen size is in that context
or do we query that from the user ?
Long Nguyen
@longnt80
Oct 03 2017 02:55
no, you only apply the font sizes when the screen size in the range of 400px to 800px
so at 400px it is at the 16px font size
at 800px it will be 24px font size
Gersho
@Gersho
Oct 03 2017 02:57
and at 800+ px ? 1 em from parent ?
Long Nguyen
@longnt80
Oct 03 2017 02:57
no parent here
just from 16px to 24px
Gersho
@Gersho
Oct 03 2017 02:57
oh at 800+ it stays 24 ok
Long Nguyen
@longnt80
Oct 03 2017 02:58
yes
so beyond 800px, your font won't get massive
Gersho
@Gersho
Oct 03 2017 02:59
and under 400 stays 16, exactly what i needed (yeah i'm a bit slow xD)
well, amazed plenty of knowledge, but i need a break or my brain is gonna melt, thanks @longnt80 @piteto and cya later
CamperBot
@camperbot
Oct 03 2017 03:03
gersho sends brownie points to @longnt80 and @piteto :sparkles: :thumbsup: :sparkles:
:cookie: 181 | @piteto |http://www.freecodecamp.com/piteto
api offline
Long Nguyen
@longnt80
Oct 03 2017 03:04
@Gersho later
piteto
@piteto
Oct 03 2017 03:04
:sparkles: :+1: :sparkles:
Albert Cardona II
@daddycardona
Oct 03 2017 03:09

LMAO @Gersho

i love js but my html/css skills are just deplorable

@piteto I had people call me that before but Pito was the main name like Papote < where that came from? I don't know lol, Papito meaning little daddy according to my grandfather and pito a shorten version lol
@Gersho use rem now I believe it is :)
piteto
@piteto
Oct 03 2017 03:48
@daddycardona I wanted it to be potato, but that and poteto were taken, so I used piteto instead :)
I should check if piteto means anything in another language
It means "drinking" in bulgarian, so that's okay :beers: :beers: :)
Gersho
@Gersho
Oct 03 2017 03:51
when i see your nickname i always think of pepito
https://seeklogo.com/images/P/Pepito-logo-8BF43F41C5-seeklogo.com.gif
piteto
@piteto
Oct 03 2017 03:53
lol :yum:
That's a really racist logo btw :joy:
Albert Cardona II
@daddycardona
Oct 03 2017 03:53
lmao
pitito or pipito lol
no it is a vato loco lol
Gersho
@Gersho
Oct 03 2017 03:54

That's a really racist logo btw :joy:

created in 1950

piteto
@piteto
Oct 03 2017 03:56
Not as bad as the logo they still use today for conguitos
Albert Cardona II
@daddycardona
Oct 03 2017 03:56
what use to be racist was run for the border lol
Gersho
@Gersho
Oct 03 2017 03:56
do you know banania ?
Albert Cardona II
@daddycardona
Oct 03 2017 03:56
no lol
hey question so
piteto
@piteto
Oct 03 2017 03:57
wow, like rastus for cream of wheat
Albert Cardona II
@daddycardona
Oct 03 2017 03:57
function findElement(arr, func) {
  var num = 0;
  return num;
}

findElement([1, 2, 3, 4], function(num){ return num % 2 === 0; });
// can I really just like foreach loop this suckker
Gersho
@Gersho
Oct 03 2017 03:58

Not as bad as the logo they still use today for conguitos

wow even worse than banania lol

Ken Haduch
@khaduch
Oct 03 2017 03:59
@daddycardona - hey there - I think that they are trying to teach the lesson that you can pass in functions as arguments, call them, and get results to r eturn?
piteto
@piteto
Oct 03 2017 04:00
I think a for loop would be better or .find() if you want to make a one-liner
Albert Cardona II
@daddycardona
Oct 03 2017 04:02
Oh Okay because I was confused what they actually wanted me to do like wth is going on here lol
Gersho
@Gersho
Oct 03 2017 04:02
what exactly is being asked in the challenge ?
are we supposed to return a single value or an array with all relevant values ?
Albert Cardona II
@daddycardona
Oct 03 2017 04:04
no we suppose to return the first value that is divisible by 2 with no remainder
heroiczero
@heroiczero
Oct 03 2017 04:04
can't you use a filter();
Albert Cardona II
@daddycardona
Oct 03 2017 04:04
I believe so, I can actually just use var itsDone = arr.filter(func);
Gersho
@Gersho
Oct 03 2017 04:04
filter will return an array, find() should do the trick
@daddycardona filter will return [2,4]
Albert Cardona II
@daddycardona
Oct 03 2017 04:05
well I am not looking for anything besides I was just trying to comprehend the exercise lol
heroiczero
@heroiczero
Oct 03 2017 04:05
yeah find() does do it
Albert Cardona II
@daddycardona
Oct 03 2017 04:05
oh okay
heroiczero
@heroiczero
Oct 03 2017 04:06
or you could just make a for and ifand a return
Albert Cardona II
@daddycardona
Oct 03 2017 04:06
arr.firstIndexOf(func) would this work?
I don't know just asking lol
Gersho
@Gersho
Oct 03 2017 04:07
i don't know, but even if it did, it would return the index of the value, not the value
heroiczero
@heroiczero
Oct 03 2017 04:07
i know there is a lastIndexOf() is there a first?
Albert Cardona II
@daddycardona
Oct 03 2017 04:08
maybe i made that up lets check @heroiczero
Gersho
@Gersho
Oct 03 2017 04:08
IndexOf already returns the first occurence
Albert Cardona II
@daddycardona
Oct 03 2017 04:08
lmao
Ken Haduch
@khaduch
Oct 03 2017 04:08
@daddycardona - you can use .filter() which will return an array of the arguments that pass the filtering function, and then just return the first element of that array, using .shift() for example, or address it as [0] to get the first element of the array.
Albert Cardona II
@daddycardona
Oct 03 2017 04:09
oh okay i never used shift yet :)
thanks @heroiczero @Gersho @khaduch
CamperBot
@camperbot
Oct 03 2017 04:09
daddycardona sends brownie points to @heroiczero and @gersho and @khaduch :sparkles: :thumbsup: :sparkles:
:star2: 3332 | @khaduch |http://www.freecodecamp.com/khaduch
:cookie: 499 | @gersho |http://www.freecodecamp.com/gersho
:star2: 1808 | @heroiczero |http://www.freecodecamp.com/heroiczero
Albert Cardona II
@daddycardona
Oct 03 2017 04:09
don't seem to hard if all fails for if is what I will go with lol
heroiczero
@heroiczero
Oct 03 2017 04:16
@daddycardona @Gersho @khaduch @piteto @DarrenfJ @Manish-Giri @longnt80 Cookies for the Freecodecamp regulars TY
CamperBot
@camperbot
Oct 03 2017 04:16
heroiczero sends brownie points to @daddycardona and @gersho and @khaduch and @piteto and @darrenfj and @manish-giri and @longnt80 :sparkles: :thumbsup: :sparkles:
:cookie: 500 | @gersho |http://www.freecodecamp.com/gersho
:cookie: 182 | @piteto |http://www.freecodecamp.com/piteto
:cookie: 575 | @longnt80 |http://www.freecodecamp.com/longnt80
:cookie: 365 | @daddycardona |http://www.freecodecamp.com/daddycardona
:star2: 2077 | @darrenfj |http://www.freecodecamp.com/darrenfj
:star2: 3333 | @khaduch |http://www.freecodecamp.com/khaduch
:star2: 6613 | @manish-giri |http://www.freecodecamp.com/manish-giri
Albert Cardona II
@daddycardona
Oct 03 2017 04:17
wow that worked .shift() at the end so easy I think LOL
Ken Haduch
@khaduch
Oct 03 2017 04:20
@daddycardona :+1:
@heroiczero - thanks to you, too - always helping out here!
CamperBot
@camperbot
Oct 03 2017 04:20
khaduch sends brownie points to @heroiczero :sparkles: :thumbsup: :sparkles:
:star2: 1809 | @heroiczero |http://www.freecodecamp.com/heroiczero
Albert Cardona II
@daddycardona
Oct 03 2017 04:23
dropElements([0, 1, 0, 1], function(n) {return n === 1;}) 
should return [1, 0, 1].

dropElements([1, 2, 3, 9, 2], function(n) {return n > 2;}) 
should return [3, 9, 2].
how does this make sense?
Gersho
@Gersho
Oct 03 2017 04:25
when it encounters a value n that makes the function return true, it returns the rest of the array (inclunding the value that triggered this) i guess ?
what does the challenge say ?
Albert Cardona II
@daddycardona
Oct 03 2017 04:26

Drop the elements of an array (first argument), starting from the front, until the predicate (second argument) returns true.

The second argument, func, is a function you'll use to test the first elements of the array to decide if you should drop it or not.

Return the rest of the array, otherwise return an empty array.

Gersho
@Gersho
Oct 03 2017 04:26
oh, i'm dumb, it drops element until you meet one that returns true, then it stops
Albert Cardona II
@daddycardona
Oct 03 2017 04:27
is that what it is trying to tell me just drop until it meats the first criteria
Gersho
@Gersho
Oct 03 2017 04:28
yes
shift you learned 5 seconds ago will prove usefull on this one i guess
but those challenges are very centered on the idea of passing function as arguments, i rarely ever use that
Albert Cardona II
@daddycardona
Oct 03 2017 04:32
I never ever saw this lol
besides the guy that was doing a challenge on here lol
Albert Cardona II
@daddycardona
Oct 03 2017 04:47
gn yall and thanks again
@Gersho
Gersho
@Gersho
Oct 03 2017 04:50
gn @daddycardona
Long Nguyen
@longnt80
Oct 03 2017 06:15
@heroiczero ty for the :cookie:
CamperBot
@camperbot
Oct 03 2017 06:15
longnt80 sends brownie points to @heroiczero :sparkles: :thumbsup: :sparkles:
:star2: 1810 | @heroiczero |http://www.freecodecamp.com/heroiczero
Long Nguyen
@longnt80
Oct 03 2017 06:17
@daddycardona @Gersho I found this document which can help greatly in learning es6: https://github.com/mbeaudru/modern-js-cheatsheet
Gersho
@Gersho
Oct 03 2017 06:19
a bit long to be considered a cheatsheet but seems interesting, thanks @longnt80
CamperBot
@camperbot
Oct 03 2017 06:19
gersho sends brownie points to @longnt80 :sparkles: :thumbsup: :sparkles:
:cookie: 576 | @longnt80 |http://www.freecodecamp.com/longnt80
Long Nguyen
@longnt80
Oct 03 2017 06:20
@Gersho well, don't mind the name :D
Jose A
@jandino
Oct 03 2017 06:30
Hello all!, this is my first time using this chat room.
are we able to put it our code here and get peer review to see what si wrong with them...?
Altin Rrahmani
@DevKosov
Oct 03 2017 06:31
Welcome. And yes you can
Gersho
@Gersho
Oct 03 2017 06:31
that's the idea yes, Welcome
Jose A
@jandino
Oct 03 2017 06:31
ok
Gersho
@Gersho
Oct 03 2017 06:31
put you code with 3 ` before and after
Jose A
@jandino
Oct 03 2017 06:31

//Programmer Jose Anidno
//CS75
//Professor Estrada

import java.util.*;

public class InternetServiceProvider
{
public static void main(String[] args)
{
int hours;// This needs to be set for the hours which will be accounted for inside the program later
char ch; //The characters need to be given a keyword to allot to be inserted into coding
Scanner in = new Scanner(System.in);// scanner needs to be created for the code
System.out.println("Enter your package name (A,B,C) ");//print overall statement to decide which packages you want to consider
ch = in.next().charAt(0);//not known
System.out.println("Enter Number of hours worked");//this will be for second entry to input how many hours after package entry
hours = in.nextInt();//not sure
double total_charge =0;//double is meant for variables with decimal points which will mainly be used or the end of the

switch(ch)
//Internet Service Provider Packages
{
case 'A':
{
if(hours<10)
total_charge=9.95;
else
total_charge=9.95+((hours-10)2.0);
}
break;
case 'B':
{
if(hours<20)
total_charge=13.95;
else
total_charge=13.95+((hours-20)
1);
}
break;
case 'C':
total_charge=19.95;
break;
default: System.out.println("Not a valid package");
}
// Monthly Bill according to hours and internet used
System.out.println("Monthly bill on Package " + ch + " is: $" +total_charge);
}
}

my professor commented--> Hey Jose your program doesn't accept data adjacent the prompt and it does not know what to do with a lower case 'b'.
and i cant figure out where i went wrong with it...or how to fix it to where it is a perfect program..
when i run it, it runs as long as i use a capitl A, B, and C. i am not sure what he means by not accepting the data adjacent
Gersho
@Gersho
Oct 03 2017 06:33

it does not know what to do with a lower case 'b'.

so you'll need an additional case i guess ?

for the rest i don't know, i don't do java (fCC doesn't do java in general, some people here know it tho, i'm not one of them :P )

Jose A
@jandino
Oct 03 2017 06:34
ohh, lol i wasnt sure if was hoping in the right chat room, i was doing fcc during summer and figured i may ask some fellow coders since i did some light coding during the previous summer
Prabu Rangki
@praburangki
Oct 03 2017 06:35
can you post it again but with proper syntax,
sorround the code with three backticks
Jose A
@jandino
Oct 03 2017 06:36
what is backticks?
Prabu Rangki
@praburangki
Oct 03 2017 06:36
`
Gersho
@Gersho
Oct 03 2017 06:36
`
Jose A
@jandino
Oct 03 2017 06:36
ok

//Programmer Jose Anidno
//CS75
//Professor Estrada

import java.util.*;

public class InternetServiceProvider
{
public static void main(String[] args)
{
int hours;// This needs to be set for the hours which will be accounted for inside the program later
char ch; //The characters need to be given a keyword to allot to be inserted into coding
Scanner in = new Scanner(System.in);// scanner needs to be created for the code
System.out.println("Enter your package name (A,a,B,C) ");//print overall statement to decide which packages you want to consider
ch = in.next().charAt(0);//not known
System.out.println("Enter Number of hours worked");//this will be for second entry to input how many hours after package entry
hours = in.nextInt();//not sure
double total_charge =0;//double is meant for variables with decimal points which will mainly be used or the end of the

switch(ch)
//Internet Service Provider Packages
{
case 'A':
{
if(hours<10)
total_charge=9.95;
else
total_charge=9.95+((hours-10)2.0);
}
break;
case;"a"
{
if(hours<10)
total_charge=9.95;
else
total_charge=9.95+((hours-10)
2.0);
}
break;

case 'B':
{
if(hours<20)
total_charge=13.95;
else
total_charge=13.95+((hours-20)*1);
}
break;
case 'C':
total_charge=19.95;
break;
default: System.out.println("Not a valid package");
}
// Monthly Bill according to hours and internet used
System.out.println("Monthly bill on Package " + ch + " is: $" +total_charge);
}
}

'''
CamperBot
@camperbot
Oct 03 2017 06:36
:bulb: to format code use backticks! ``` more info
Prabu Rangki
@praburangki
Oct 03 2017 06:36
import java.util.*;
public class InternetServiceProvider
{
public static void main(String[] args)
{
int hours;// This needs to be set for the hours which will be accounted for inside the program later
char ch; //The characters need to be given a keyword to allot to be inserted into coding
Scanner in = new Scanner(System.in);// scanner needs to be created for the code
System.out.println("Enter your package name (A,B,C) ");//print overall statement to decide which packages you want to consider
ch = in.next().charAt(0);//not known
System.out.println("Enter Number of hours worked");//this will be for second entry to input how many hours after package entry
hours = in.nextInt();//not sure
double total_charge =0;//double is meant for variables with decimal points which will mainly be used or the end of the
switch(ch)
//Internet Service Provider Packages
{
case 'A':
{
if(hours<10)
total_charge=9.95;
else
total_charge=9.95+((hours-10)2.0);
}
break;
case 'B':
{
if(hours<20)
total_charge=13.95;
else
total_charge=13.95+((hours-20)1);
}
break;
case 'C':
total_charge=19.95;
break;
default: System.out.println("Not a valid package");
}
// Monthly Bill according to hours and internet used
System.out.println("Monthly bill on Package " + ch + " is: $" +total_charge);
}
}
Jose A
@jandino
Oct 03 2017 06:37
thank you, i havnt done that before
Prabu Rangki
@praburangki
Oct 03 2017 06:39
i don't think you need the curly braces after each case
Jose A
@jandino
Oct 03 2017 06:40
oh, i can just leave them out? ok that is helpful i will try that, but any recomendation for allowing the use of non capital letters?
Prabu Rangki
@praburangki
Oct 03 2017 06:41
you can force the input to be lowercase with this toLowerCase()
Jose A
@jandino
Oct 03 2017 06:43
where could i appropriatley insert this without having to mess with the code too much?
by the enter package name?
Prabu Rangki
@praburangki
Oct 03 2017 06:44
you can try ch = in.next().toLowerCase().charAt(0)
Jose A
@jandino
Oct 03 2017 06:46
it doesnt allow my code to finish, it will allow me to enter the letter, and the number of hours used, but after that it wont acknoledge my input, or allow my code to finish
BuntyBru
@BuntyBru
Oct 03 2017 09:11
By any chance anyone knows a person working in retail
Its very necessary
Please help
Stephen James
@sjames1958gm
Oct 03 2017 10:08
@jandino If you use toLowerCase then you will need to change your cases to case 'a': from case 'A':
Or you could use toUpperCase instead
Darren
@DarrenfJ
Oct 03 2017 14:52
morning fCC
another quiet day in the helpMines?
Stephen James
@sjames1958gm
Oct 03 2017 15:19
yep
Darren
@DarrenfJ
Oct 03 2017 15:24
dang
thanks for the kudos @heroiczero
CamperBot
@camperbot
Oct 03 2017 15:25
darrenfj sends brownie points to @heroiczero :sparkles: :thumbsup: :sparkles:
:star2: 1812 | @heroiczero |http://www.freecodecamp.com/heroiczero
Darren
@DarrenfJ
Oct 03 2017 15:25
and thanks @sjames1958gm for hanging out and helping everyone
CamperBot
@camperbot
Oct 03 2017 15:25
darrenfj sends brownie points to @sjames1958gm :sparkles: :thumbsup: :sparkles:
:star2: 8508 | @sjames1958gm |http://www.freecodecamp.com/sjames1958gm
Darren
@DarrenfJ
Oct 03 2017 15:25
will pop back in later
code on
Stephen James
@sjames1958gm
Oct 03 2017 15:25
@DarrenfJ :+1:
qnagr
@qnagr
Oct 03 2017 16:49
Hi, on my laptop, when I use to elements with ms (bootstrap), they stack vertically but when I use xs they work fine. Why is this?
*columns with ms
Pethaf
@Pethaf
Oct 03 2017 16:53
Don't you mean md ?
I.e. col-md-4 ?
qnagr
@qnagr
Oct 03 2017 16:54
I JUST realized it
thanks
Mike
@MikeJSchorah
Oct 03 2017 18:27
Has anyone here ever used a dedicated server?
Jan Shah
@JanShah
Oct 03 2017 18:30
@MikeJSchorah a few times.
Mike
@MikeJSchorah
Oct 03 2017 18:30
@JanShah Are they difficult to use?
Jan Shah
@JanShah
Oct 03 2017 18:31
depends on if you get a bare server you have to install software on, or a managed server with cpanel and whm. if ou have the latter, which is much more common, it's as easy as any cpanel hosting, just more access
@MikeJSchorah
Mike
@MikeJSchorah
Oct 03 2017 18:49
Thanks @JanShah
CamperBot
@camperbot
Oct 03 2017 18:49
mikejschorah sends brownie points to @janshah :sparkles: :thumbsup: :sparkles:
:cookie: 552 | @janshah |http://www.freecodecamp.com/janshah
Albert Cardona II
@daddycardona
Oct 03 2017 20:51
@longnt80 thanks for that site :)
CamperBot
@camperbot
Oct 03 2017 20:51
daddycardona sends brownie points to @longnt80 :sparkles: :thumbsup: :sparkles:
:cookie: 579 | @longnt80 |http://www.freecodecamp.com/longnt80
Albert Cardona II
@daddycardona
Oct 03 2017 20:52
what up coders how yall doing ;)
@JanShah have you used a bare server, and if so what software did you put on it?
Alex Brown
@webtechalex
Oct 03 2017 21:40
Hi All. I’m just checking out the React Projects and have been playing with the Markdown Previewer. Trying to get the suggested ‘marked’ library working and found that I’m getting an error in my browser console (Chrome): “Refused to execute script from 'https://cdnjs.com/libraries/marked' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.” Had a look at the Chrome settings to see if I could find out how to disable Strict MIME type checking but I couldn’t find it. Don’t even know if it’s something I should be looking to disable or whether it will have any effect in solving the problem. Is there another workaround for this or another CDN address that actually makes this tool work?
@webtechalex You are linking html page
Alex Brown
@webtechalex
Oct 03 2017 21:42
got it. That link is on the page whose link I was using!
Thanks @korzo
CamperBot
@camperbot
Oct 03 2017 21:42
webtechalex sends brownie points to @korzo :sparkles: :thumbsup: :sparkles:
:cookie: 571 | @korzo |http://www.freecodecamp.com/korzo
Mike
@MikeJSchorah
Oct 03 2017 22:52
@JanShah After I point my domain name to the dedicated server, how do I go about getting into the cPanel?
korzo
@korzo
Oct 03 2017 22:54
@MikeJSchorah There is no cPanel on dedicated server, unless your provider installed it.
Mike
@MikeJSchorah
Oct 03 2017 22:57
image.png
@korzo
korzo
@korzo
Oct 03 2017 23:01
@MikeJSchorah try https://domainame:2083/
Mike
@MikeJSchorah
Oct 03 2017 23:10
@korzo Yeah, doesn't seem to be working. I tried https://domainame/cpanel/ an hour ago. Someone suggested it to me
korzo
@korzo
Oct 03 2017 23:14
@MikeJSchorah Well , I never worked on dedicated server from Godaddy, but this are usual locations of cPanel
Isn't there link, when you click on cPanel link under domain name ?
@MikeJSchorah Its on port 2083. I tried it on one of your domains
Mike
@MikeJSchorah
Oct 03 2017 23:18
Not sure. Never used GoDaddy
korzo
@korzo
Oct 03 2017 23:20
@MikeJSchorah Just add :2083 after domain name as I wrote before
Mike
@MikeJSchorah
Oct 03 2017 23:23
I know. It's timing out @korzo
korzo
@korzo
Oct 03 2017 23:24
@MikeJSchorah Strange, It loads for me
Mike
@MikeJSchorah
Oct 03 2017 23:25
@korzo It's in the server's cPanel. gotoadoc.com isn't
Justin25
@Justin25
Oct 03 2017 23:35
So I was just coding and accidentally switched to a different branch in git hub but I haven't pushed what I was working on to git hub. Is there a way to get it back?
I did commit locally just before this happened.
korzo
@korzo
Oct 03 2017 23:38
@Justin25 You want to move commit to different branch?
Justin25
@Justin25
Oct 03 2017 23:39
No, I made commit locally then changed branches and now all of the changes I made are gone.
I just want the chnages from the last commit back
korzo
@korzo
Oct 03 2017 23:41
@Justin25 So switch back to previous branch?
Justin25
@Justin25
Oct 03 2017 23:42
I switched back to the branch but my last local commit is gone
korzo
@korzo
Oct 03 2017 23:48
@Justin25 Commit can't disappear unless you deleted local repository and cloned from github again
@Justin25 anyway, take a look in reflog. It should be there
Justin25
@Justin25
Oct 03 2017 23:52
Where do I find that?
@korzo
korzo
@korzo
Oct 03 2017 23:54
@Justin25 git reflog
@Justin25 Or if you use some application for Git, search for "References"
Justin25
@Justin25
Oct 03 2017 23:57
Ok so I found the commit how do I recover it
I got this code a7eff6f
korzo
@korzo
Oct 03 2017 23:58
@Justin25 Do you use some application for git or git from command line?
Justin25
@Justin25
Oct 03 2017 23:58
Command line
Ok so git reset --hard a7eff6f worked