๐
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| { | |
| "capabilities": | |
| [ | |
| { | |
| "browserName": "firefox", | |
| "maxInstances": 10 | |
| } | |
| ], | |
| "port":5555, | |
| "hubPort":4444, |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/bin/bash | |
| case "${1:-''}" in | |
| 'start') | |
| if test -f /tmp/selenium.pid | |
| then | |
| echo "Selenium is already running." | |
| else | |
| export DISPLAY=localhost:99.0 | |
| java -Dwebdriver.gecko.driver="/usr/lib/geckodriver/geckodriver" -jar /usr/lib/selenium/selenium-server-standalone.jar -port 4444 > /var/log/selenium/output.log 2> /var/log/selenium/error.log & echo $! > /tmp/selenium.pid |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| #include <iostream> | |
| using namespace std; | |
| void multiplyAndDivide (int x, int y, int& mul, double& div) { | |
| mul = x * y; | |
| div = (x * 1.0) / y; | |
| } | |
| int main() { | |
| int n1, n2, m; | |
| double d; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| void multiplyAndDivide (int x, int y, int& mul, double& div) { | |
| mul = x * y; | |
| div = (x * 1.0) / y; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| #include <iostream> | |
| using namespace std; | |
| bool isVowel (char x) { | |
| char y = toupper(x); | |
| return (y=='A' || y=='E' || y=='I'|| y=='O'|| y=='U'); | |
| } | |
| int main() { | |
| cout<< isVowel('a'); | |
| return 0; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| bool isVowel (char x) { | |
| return (x == 'A' || x == 'a' || | |
| x == 'E' || x == 'e' || | |
| x == 'I' || x == 'i' || | |
| x == 'O' || x == 'o' || | |
| x == 'U' || x == 'u'); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| bool isVowel (char x) { | |
| char y = toupper(x); | |
| return (y=='A' || y=='E' || y=='I'|| y=='O'|| y=='U'); | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| class ArrayQueue { | |
| private final int[] queue; | |
| private int first = 0; | |
| private int last = 0; | |
| int size = 0; | |
| public ArrayQueue(int size) { | |
| queue = new int[size]; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| class ArrayStack { | |
| private final int[] stack; | |
| private final int size; | |
| private int top; | |
| public ArrayStack(int size) { | |
| this.size = size; | |
| stack = new int[size]; | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // www.abukhleif.com | |
| void EvenOdd (int num, int& evens, int& odds) { | |
| evens = odds = 0; | |
| while (num != 0) { | |
| if (num % 2 == 0) | |
| evens++; | |
| else | |
| odds++; | |
| num /= 10; | |
| } |