Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
import java.util.concurrent.RecursiveTask; | |
public class ArraySumCalculator extends RecursiveTask<Long> { | |
private static final int THRESHOLD = 1000; // Threshold for splitting the array | |
private final int[] array; | |
private final int start; | |
private final int end; | |
public ArraySumCalculator(int[] array, int start, int end) { | |
this.array = array; |
This file contains 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
import java.util.concurrent.CountDownLatch; | |
import java.util.Random; | |
import java.util.logging.Level; | |
import java.util.logging.Logger; | |
class Participant implements Runnable { | |
private final CountDownLatch latch; | |
private final Random random = new Random(); | |
private long id; | |
private static final Logger LOGGER = Logger.getLogger(Participant.class.getName()); |
This file contains 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
function sheetName() { | |
var spreedsheet = SpreadsheetApp.getActiveSpreadsheet(); | |
const monthNames = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"]; | |
const monthSheets = monthNames.map(name => spreedsheet.getSheetByName(name)); | |
const COLUMN_START = 6; | |
const DAYS_COUNT = 31; | |
for(var i=0; i < monthSheets.length; i++) { |
This file contains 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
function numberToLetter(number){ | |
var temp = "" | |
var letter = ""; | |
while (number > 0){ | |
temp = (number - 1) % 26; | |
letter = String.fromCharCode(temp + 65) + letter; | |
number = (number - temp - 1) / 26; | |
} | |
return letter; | |
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
class Docking: | |
""" | |
Implementacje: | |
* oddt.docking.autodock_vina | |
* custom engine } | |
* oddt.docking.rdock } nowe klasy | |
""" | |
def set_protein(self, protein): pass | |
def set_writer(self, writer): # writer of type MolWriter |
This file contains 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
#!/usr/bin/env bash | |
rm -f mine/tests/*.out | |
for f in tests/*.in | |
do | |
./pol < $f > mine/$f | |
# do something on $f | |
done | |
cd mine/tests |
This file contains 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
import numpy as np | |
import matplotlib.pyplot as plt | |
fig = plt.figure() | |
ax = fig.gca(projection='3d') | |
theta = np.linspace(-4 * np.pi, 4 * np.pi, 100) | |
z = np.linspace(-2, 2, 100) | |
r = z**2 + 1 | |
x = r * np.sin(theta) | |
y = r * np.cos(theta) |
NewerOlder