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
import binascii | |
import duckdb | |
import io | |
import numpy as np | |
def makeblob(arr): | |
f = io.BytesIO() | |
np.save(f, arr) | |
f.seek(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
DueDate: | |
type: date | |
properties: | |
attr: | |
class: datepicker | |
label_attr: | |
class: required | |
Type: | |
type: choice | |
properties: |
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
<?php | |
namespace App\Forms\Entities; | |
use App\Forms\YamlConfigForm as Form; | |
use App\Models\Agency; | |
use App\Models\Service; | |
class ServiceForm extends Form | |
{ | |
public function getModelClass() |
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
<?php | |
namespace App\Forms; | |
use Kris\LaravelFormBuilder\Form; | |
use Yaml; | |
use Carbon\Carbon; | |
use App\Forms\Report\FormConfig; | |
use App\Forms\Entities\EntityFormConfig; | |
use App\Services\ReportServices\ReportStringProcessingTrait; |
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
class Rule: | |
def matchesRule(self, number): | |
pass | |
def getReplacement(self): | |
pass | |
class FizzRule: | |
def matchesRule(self, number): | |
return not (number % 3); |
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
class FizzRule: | |
def matchesRule(self, number): | |
return not (number % 3); | |
def getReplacement(self): | |
return "Fizz"; | |
class BuzzRule: | |
def matchesRule(self, number): | |
return not (number % 5); |
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
return $id ? "The item was updated." : "The item was created"; | |
######## | |
$action = $id ? "updated" : "created"; | |
return sprintf("The item was %s.", $action). |
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
return 'The number is ' + str(2) + '.' | |
return 'The number is %s.' % 2 |
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
return sprintf("%0.3f",$number); | |
return number_format($number, 3, '.', ''); |
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
return sprintf( | |
“The user %s %s has a balance of $%f.”, | |
$firstName, | |
$lastName, | |
$balance | |
); | |
return "The user " . $firstName . " has a balance of $" . $balance . "."; |
NewerOlder